Skip to content
This repository has been archived by the owner on Apr 26, 2024. It is now read-only.

Commit

Permalink
Update synapse/storage/_base.py
Browse files Browse the repository at this point in the history
Co-authored-by: reivilibre <[email protected]>
  • Loading branch information
Mathieu Velten and reivilibre committed Sep 20, 2022
1 parent 3d55375 commit b5bc334
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions synapse/storage/_base.py
Original file line number Diff line number Diff line change
Expand Up @@ -117,10 +117,8 @@ def _attempt_to_invalidate_cache(
cache = getattr(self, cache_name)
except AttributeError:
# Check if an externally defined module cache has been registered
external_func = self.external_cached_functions.get(cache_name)
if external_func:
cache = external_func
else:
cache = self.external_cached_functions.get(cache_name)
if not cache:
# We probably haven't pulled in the cache in this worker,
# which is fine.
return False
Expand Down

0 comments on commit b5bc334

Please sign in to comment.