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

+ 8 - 0
src/server/service/import.js

@@ -476,6 +476,14 @@ class ImportService {
     // - import: throw err if there are pending migrations
   }
 
+  // 追加
+  validateVersionforUploading(meta) {
+    if (meta.version !== this.crowi.version) {
+      const versionErr = new Error('the version of this growi and the growi that exported the data are not met');
+      return versionErr;
+    }
+  }
+
   /**
    * Delete all uploaded files
    */