Explorar el Código

fix(page): Add rules creatable name

Closes #33
Keisuke SATO hace 10 años
padre
commit
d5618b1fcb
Se han modificado 1 ficheros con 2 adiciones y 1 borrados
  1. 2 1
      lib/models/page.js

+ 2 - 1
lib/models/page.js

@@ -183,11 +183,12 @@ module.exports = function(crowi) {
 
   pageSchema.statics.isCreatableName = function(name) {
     var forbiddenPages = [
-      /\^|\$|\*|\+/,
+      /\^|\$|\*|\+|\#/,
       /^\/_api\/.*/,
       /^\/\-\/.*/,
       /^\/_r\/.*/,
       /.+\/edit$/,
+      /\/$/,
       /^\/(installer|register|login|logout|admin|me|files|trash|paste|comments).+/,
     ];