Revert "policies: don't always clear application cache on post_save"

This reverts commit 5ef385f0bb.

Signed-off-by: Jens Langhammer <jens.langhammer@beryju.org>

# Conflicts:
#	authentik/policies/signals.py
This commit is contained in:
Jens Langhammer 2021-12-22 00:23:19 +01:00
parent e60509697a
commit 16b6c17305
1 changed files with 3 additions and 3 deletions

View File

@ -23,6 +23,6 @@ def invalidate_policy_cache(sender, instance, **_):
total += len(keys) total += len(keys)
cache.delete_many(keys) cache.delete_many(keys)
LOGGER.debug("Invalidating policy cache", policy=instance, keys=total) LOGGER.debug("Invalidating policy cache", policy=instance, keys=total)
# Also delete user application cache # Also delete user application cache
keys = cache.keys(user_app_cache_key("*")) or [] keys = cache.keys(user_app_cache_key("*")) or []
cache.delete_many(keys) cache.delete_many(keys)