Skip to content

armgit / ente

Public Imported from GitHub
0

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

fix hidden files embeddings

Abhinav2ed6efe41963
diff --git a/apps/photos/src/services/embeddingService.ts b/apps/photos/src/services/embeddingService.ts
index 4df203072d..400fc23cc3 100644
--- a/apps/photos/src/services/embeddingService.ts
+++ b/apps/photos/src/services/embeddingService.ts
@@ -9,7 +9,7 @@ import { getEndpoint } from 'utils/common/apiUtil';
import { addLogLine } from 'utils/logging';
import { logError } from 'utils/sentry';
import localForage from 'utils/storage/localForage';
-import { getLocalFiles } from './fileService';
+import { getAllLocalFiles } from './fileService';
import HTTPService from './HTTPService';
import { getToken } from 'utils/common/key';
import { getLatestVersionEmbeddings } from 'utils/embedding';
@@ -41,7 +41,7 @@ export const getLatestEmbeddings = async () => {
export const syncEmbeddings = async () => {
try {
let embeddings = await getLocalEmbeddings();
- const localFiles = await getLocalFiles();
+ const localFiles = await getAllLocalFiles();
const localTrashFiles = await getLocalTrashedFiles();
const fileIdToKeyMap = new Map<number, string>();
[...localFiles, ...localTrashFiles].forEach((file) => {
@@ -159,7 +159,7 @@ export const putEmbedding = async (
};
export const cleanupDeletedEmbeddings = async () => {
- const files = await getLocalFiles();
+ const files = await getAllLocalFiles();
const trashedFiles = await getLocalTrashedFiles();
const activeFileIds = new Set<number>();
[...files, ...trashedFiles].forEach((file) => {