π End-to-end encrypted cloud for everything.
Dart 2faandroidauthye2eeencryptionend-to-end-encryptionfluttergolanggoogle-photosgoogle-photos-alternativeiosopensourcephotosprivacyprivacy-toolstypescriptzero-knowledge
[mob][photos] cached public collectionID
Aman Raj Singh Mouryaac656cfe9f80
diff --git a/mobile/lib/utils/diff_fetcher.dart b/mobile/lib/utils/diff_fetcher.dartindex bfff3ebd3b..409c76de7c 100644--- a/mobile/lib/utils/diff_fetcher.dart+++ b/mobile/lib/utils/diff_fetcher.dart@@ -82,7 +82,7 @@ class DiffFetcher {'diff items ( ${sharedFiles.length} updated) in ${DateTime.now().difference(startTime).inMilliseconds}ms');return sharedFiles;} catch (e, s) {- _logger.severe("Failed to decrypt collection $e", s);+ _logger.severe("Failed to decrypt collection ", e, s);rethrow;}}diff --git a/mobile/lib/utils/file_download_util.dart b/mobile/lib/utils/file_download_util.dartindex 17d58a2ea4..a96017568f 100644--- a/mobile/lib/utils/file_download_util.dart+++ b/mobile/lib/utils/file_download_util.dart@@ -97,9 +97,8 @@ Future<File?> downloadAndDecrypt(EnteFile file, {ProgressCallback? progressCallback,}) async {- final authToken =- await CollectionsService.instance.getPublicAlbumToken(file.collectionID!);- if (authToken != null) {+ if (await CollectionsService.instance+ .isPublicCollection(file.collectionID!)) {final authToken = await CollectionsService.instance.getPublicAlbumToken(file.collectionID!);diff --git a/mobile/lib/utils/thumbnail_util.dart b/mobile/lib/utils/thumbnail_util.dartindex aa8750ee6a..8545fbdc9e 100644--- a/mobile/lib/utils/thumbnail_util.dart+++ b/mobile/lib/utils/thumbnail_util.dart@@ -161,9 +161,10 @@ Future<void> _downloadAndDecryptThumbnail(FileDownloadItem item) async {final file = item.file;Uint8List encryptedThumbnail;try {- final authToken = await CollectionsService.instance- .getPublicAlbumToken(file.collectionID!);- if (authToken != null) {+ if (await CollectionsService.instance+ .isPublicCollection(file.collectionID!)) {+ final authToken = await CollectionsService.instance+ .getPublicAlbumToken(file.collectionID!);final authJWTToken = await CollectionsService.instance.getPublicAlbumTokenJWT(file.collectionID!);