]> git.mjollnir.org Git - s9y.git/commitdiff
don't allow empty permalinks, should help with some i18n trouble
authorgarvinhicking <garvinhicking>
Mon, 14 Nov 2005 09:04:18 +0000 (09:04 +0000)
committergarvinhicking <garvinhicking>
Mon, 14 Nov 2005 09:04:18 +0000 (09:04 +0000)
include/functions_permalinks.inc.php

index d408ee4273f13ea82bfec9d8510aa31c4edf499b..5ee05a1a94720c5e2afd7bc851e4983c064380ee 100644 (file)
@@ -113,6 +113,14 @@ function serendipity_makeFilename($str) {
     // Remove excess separators
     $str = trim($str, $to[0]);
 
+    if (empty($str)) {
+        if (isset($GLOBALS['i18n_unknown'])) {
+            $str = $GLOBALS['i18n_unknown'];
+        } else {
+            $str = 'unknown';
+        }
+    }
+
     return $str;
 }