Manav Rathi 1 рік тому
батько
коміт
14922b65f8
1 змінених файлів з 1 додано та 11 видалено
  1. 1 11
      web/apps/photos/src/services/export/migration.ts

+ 1 - 11
web/apps/photos/src/services/export/migration.ts

@@ -200,11 +200,7 @@ async function migrateCollectionFolders(
 ) {
     const fs = ensureElectron().fs;
     for (const collection of collections) {
-        const oldCollectionExportPath = getOldCollectionFolderPath(
-            exportDir,
-            collection.id,
-            collection.name,
-        );
+        const oldCollectionExportPath = `${exportDir}/${collection.id}_${oldSanitizeName(collection.name)}`;
         const newCollectionExportPath = await safeDirectoryName(
             exportDir,
             collection.name,
@@ -494,12 +490,6 @@ const oldSanitizeName = (name: string) =>
 const getFileSavePath = (collectionFolderPath: string, fileSaveName: string) =>
     `${collectionFolderPath}/${fileSaveName}`;
 
-const getOldCollectionFolderPath = (
-    dir: string,
-    collectionID: number,
-    collectionName: string,
-) => `${dir}/${collectionID}_${oldSanitizeName(collectionName)}`;
-
 const getUniqueFileExportNameForMigration = (
     collectionPath: string,
     filename: string,