π End-to-end encrypted cloud for everything.
Dart 2faandroidauthye2eeencryptionend-to-end-encryptionfluttergolanggoogle-photosgoogle-photos-alternativeiosopensourcephotosprivacyprivacy-toolstypescriptzero-knowledge
Initialize and reset shared feed cutoff on auth state changes
ashilkne4758204eda1
diff --git a/mobile/apps/photos/lib/core/configuration.dart b/mobile/apps/photos/lib/core/configuration.dartindex 12737a0625..f15ccd3794 100644--- a/mobile/apps/photos/lib/core/configuration.dart+++ b/mobile/apps/photos/lib/core/configuration.dart@@ -210,6 +210,9 @@ class Configuration {}}+ // Reset feed cutoff so it is recreated for the next login session.+ await localSettings.clearSharedPhotoFeedCutoffTime();+// Clear preferences and secure storageawait _preferences.clear();await _secureStorage.deleteAll();diff --git a/mobile/apps/photos/lib/services/account/user_service.dart b/mobile/apps/photos/lib/services/account/user_service.dartindex 412ed2e1ed..ebf2ab8a80 100644--- a/mobile/apps/photos/lib/services/account/user_service.dart+++ b/mobile/apps/photos/lib/services/account/user_service.dart@@ -1178,6 +1178,9 @@ class UserService {} else {await Configuration.instance.setToken(responseData["token"]);}++ // Initialize shared feed cutoff at login; feed path keeps the same fallback.+ localSettings.getOrCreateSharedPhotoFeedCutoffTime();}Future<void> setTwoFactor({diff --git a/mobile/apps/photos/lib/utils/local_settings.dart b/mobile/apps/photos/lib/utils/local_settings.dartindex d7832823df..6bdb9363e0 100644--- a/mobile/apps/photos/lib/utils/local_settings.dart+++ b/mobile/apps/photos/lib/utils/local_settings.dart@@ -435,6 +435,10 @@ class LocalSettings {return cutoff;}+ Future<void> clearSharedPhotoFeedCutoffTime() async {+ await _prefs.remove(_kSharedPhotoFeedCutoffTime);+ }+int wrapped2025ResumeIndex() {return _prefs.getInt(_kWrapped2025ResumeIndex) ?? 0;}