Skip to content

armgit / ente

Public Imported from GitHub
0

πŸ’š End-to-end encrypted cloud for everything.

Remove old types

Manav Rathicdc45e9fcc68
diff --git a/web/apps/photos/src/services/watch.ts b/web/apps/photos/src/services/watch.ts
index c7bd04dedf..6c302b179b 100644
--- a/web/apps/photos/src/services/watch.ts
+++ b/web/apps/photos/src/services/watch.ts
@@ -6,14 +6,13 @@
import { ensureElectron } from "@/next/electron";
import { nameAndExtension } from "@/next/file";
import log from "@/next/log";
-import type { CollectionMapping, FolderWatch } from "@/next/types/ipc";
+import type { CollectionMapping, FolderWatch, FolderWatchSyncedFile } from "@/next/types/ipc";
import { UPLOAD_RESULT } from "constants/upload";
import debounce from "debounce";
import uploadManager from "services/upload/uploadManager";
import { Collection } from "types/collection";
import { EncryptedEnteFile } from "types/file";
import { ElectronFile, FileWithCollection } from "types/upload";
-import { WatchMappingSyncedFile } from "types/watchFolder";
import { groupFilesBasedOnCollectionID } from "utils/file";
import { isSystemFile } from "utils/upload";
import { removeFromCollection } from "./collectionService";
@@ -477,7 +476,7 @@ class WatchFolderService {
private async trashByIDs(toTrashFiles: FolderWatch["syncedFiles"]) {
try {
const files = await getLocalFiles();
- const toTrashFilesMap = new Map<number, WatchMappingSyncedFile>();
+ const toTrashFilesMap = new Map<number, FolderWatchSyncedFile>();
for (const file of toTrashFiles) {
toTrashFilesMap.set(file.uploadedFileID, file);
}
diff --git a/web/apps/photos/src/types/watchFolder/index.ts b/web/apps/photos/src/types/watchFolder/index.ts
deleted file mode 100644
index dda243e557..0000000000
--- a/web/apps/photos/src/types/watchFolder/index.ts
+++ /dev/null
@@ -1,15 +0,0 @@
-import { UPLOAD_STRATEGY } from "constants/upload";
-
-export interface WatchMappingSyncedFile {
- path: string;
- uploadedFileID: number;
- collectionID: number;
-}
-
-export interface WatchMapping {
- rootFolderName: string;
- folderPath: string;
- uploadStrategy: UPLOAD_STRATEGY;
- syncedFiles: WatchMappingSyncedFile[];
- ignoredFiles: string[];
-}