From 059111068a19c776169bd3b4cb41d5f89878e2e0 Mon Sep 17 00:00:00 2001 From: Felix Stupp Date: Tue, 6 Dec 2022 13:12:10 +0100 Subject: [PATCH] update_element_lookup_cache on forced single update --- server/app.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/server/app.py b/server/app.py index 981593f..9572f7c 100644 --- a/server/app.py +++ b/server/app.py @@ -833,7 +833,9 @@ def force_refresh_collection(collection_id: int) -> ResponseReturnValue: coll: MediaCollection = MediaCollection.get(id=collection_id) if coll is None: return "404 Not Found", 404 - collection_update(coll, check_cache_expired=False) + state = collection_update(coll, check_cache_expired=False) + if state.may_has_changed: + update_element_lookup_cache((coll.id,)) return redirect_back_or_okay()