Sotaro KARASAWA 10 лет назад
Родитель
Сommit
b9dadcfc60
2 измененных файлов с 2 добавлено и 2 удалено
  1. 1 1
      lib/models/page.js
  2. 1 1
      resource/js/crowi.js

+ 1 - 1
lib/models/page.js

@@ -10,7 +10,7 @@ module.exports = function(crowi) {
     , pageSchema;
 
   function isPortalPath(path) {
-    if (path.match(/.+\/$/)) {
+    if (path.match(/.*\/$/)) {
       return true;
     }
 

+ 1 - 1
resource/js/crowi.js

@@ -301,7 +301,7 @@ $(function() {
     var path = $link.data('path');
     var shortPath = $link.data('short-path');
 
-    $link.html(path.replace(new RegExp(shortPath + '/?$'), '<strong>' + shortPath + '</strong>'));
+    $link.html(path.replace(new RegExp(shortPath + '(/)?$'), '<strong>' + shortPath + '$1</strong>'));
   });