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

rename the validation method to understand easier

kaoritokashiki 5 лет назад
Родитель
Сommit
0b034afff3
2 измененных файлов с 2 добавлено и 2 удалено
  1. 1 1
      src/server/routes/apiv3/import.js
  2. 1 1
      src/server/service/import.js

+ 1 - 1
src/server/routes/apiv3/import.js

@@ -312,7 +312,7 @@ module.exports = (crowi) => {
 
 
       // validate with meta.json
       // validate with meta.json
       // importService.validate(data.meta);  元々これのみ
       // importService.validate(data.meta);  元々これのみ
-      const versionErr = importService.validateVersionforUploading(data.meta);
+      const versionErr = importService.validateUploadedVersion(data.meta);
       if (versionErr !== null) {
       if (versionErr !== null) {
         return res.apiv3({ data, versionErr }); // versionErrはobjではないので恐らくこの書き方は間違い
         return res.apiv3({ data, versionErr }); // versionErrはobjではないので恐らくこの書き方は間違い
       }
       }

+ 1 - 1
src/server/service/import.js

@@ -477,7 +477,7 @@ class ImportService {
   }
   }
 
 
   // 追加
   // 追加
-  validateVersionforUploading(meta) {
+  validateUploadedVersion(meta) {
     if (meta.version !== this.crowi.version) {
     if (meta.version !== this.crowi.version) {
       const versionErr = new Error('the version of this growi and the growi that updated data are not met');
       const versionErr = new Error('the version of this growi and the growi that updated data are not met');
       return versionErr;
       return versionErr;