From a310fbe14fd6366f336abbf001719271c012e016 Mon Sep 17 00:00:00 2001 From: Neeraj Gupta <254676+ua741@users.noreply.github.com> Date: Wed, 18 Jun 2025 11:07:19 +0530 Subject: [PATCH] Skip hash check for local only assets --- mobile/lib/services/local_file_update_service.dart | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) 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(