fix filename parsing master github/master
authorAndreas Resch <[email protected]>
Thu, 4 Jul 2024 06:39:44 +0000 (08:39 +0200)
committerChristian Weiske <[email protected]>
Tue, 18 Mar 2025 19:33:22 +0000 (20:33 +0100)
.gitignore
surrogator.php

index b3d2101bb02e657ecca5db51e1e723c7ffe08145..b9296acfce0451b136479351941d04169a865688 100644 (file)
@@ -8,3 +8,4 @@ www/robots.txt
 build.properties
 dist/
 /vendor/
+/.idea/
index b397042d1603d24c129ee9adaa94fed8aea2a8de..0b66c8a8b73e0e13c4fdbb0f94a8057ff9df3aba 100755 (executable)
@@ -205,7 +205,7 @@ function getHashes($fileName)
     //OpenIDs have their slashes "/" url-encoded
     $fileName = rawurldecode($fileName);
 
-    $fileNameNoExt = substr($fileName, 0, -strlen(strrpos($fileName, '.')) - 2);
+    $fileNameNoExt = pathinfo($fileName, PATHINFO_FILENAME);
     $emailAddress  = trim(strtolower($fileNameNoExt));
 
     return array(