Skip to content

armgit / ente

Public Imported from GitHub
0

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

Skip hash check for local only assets

Neeraj Guptaa310fbe14fd6
diff --git a/mobile/lib/services/local_file_update_service.dart b/mobile/lib/services/local_file_update_service.dart
index 0f9c48dcc0..938e8067d2 100644
--- a/mobile/lib/services/local_file_update_service.dart
+++ b/mobile/lib/services/local_file_update_service.dart
@@ -155,6 +155,11 @@ class LocalFileUpdateService {
if (processedIDs.contains(file.localID)) {
continue;
}
+ if (!file.isUploaded) {
+ _logger.info("File ${file.tag} is not uploaded, skipping hash check");
+ processedIDs.add(file.localID!);
+ continue;
+ }
MediaUploadData uploadData;
try {
uploadData = await getUploadData(file);
@@ -202,8 +207,8 @@ class LocalFileUpdateService {
_logger.severe("failed to check hash: invalid file ${file.tag}", e);
}
processedIDs.add(file.localID!);
- } catch (e) {
- _logger.severe("Failed to check hash", e);
+ } catch (e, s) {
+ _logger.severe("Failed to check hash", e, s);
} finally {}
}
await _fileUpdationDB.deleteByLocalIDs(