Просмотр исходного кода

replace only the end of period

soumaeda 2 лет назад
Родитель
Сommit
9ea0fbf14c
1 измененных файлов с 1 добавлено и 1 удалено
  1. 1 1
      apps/app/src/server/routes/apiv3/page.js

+ 1 - 1
apps/app/src/server/routes/apiv3/page.js

@@ -619,7 +619,7 @@ module.exports = (crowi) => {
 
 
     const fileName = path.basename(pagePath)
     const fileName = path.basename(pagePath)
       .replace(/[\\/:;"*?<>,」ˆ|]/g, '_')
       .replace(/[\\/:;"*?<>,」ˆ|]/g, '_')
-      .replace(/.$/, '_');
+      .replace(/\.$/, '_');
     let stream;
     let stream;
 
 
     try {
     try {