Skip to content

Commit

Permalink
fix(mobile): rebuild of unified partner timeline (immich-app#5065)
Browse files Browse the repository at this point in the history
  • Loading branch information
fyfrey authored Nov 15, 2023
1 parent f54e6fc commit 343afea
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions mobile/lib/shared/models/store.dart
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@ class Store {

/// Stores the value synchronously in the cache and asynchronously in the DB
static Future<void> put<T>(StoreKey<T> key, T value) {
if (_cache[key.id] == value) return Future.value();
_cache[key.id] = value;
return _db.writeTxn(
() async => _db.storeValues.put(await StoreValue._of(value, key)),
Expand All @@ -52,6 +53,7 @@ class Store {

/// Removes the value synchronously from the cache and asynchronously from the DB
static Future<void> delete<T>(StoreKey<T> key) {
if (_cache[key.id] == null) return Future.value();
_cache[key.id] = null;
return _db.writeTxn(() => _db.storeValues.delete(key.id));
}
Expand Down

0 comments on commit 343afea

Please sign in to comment.