From 4f1258431088804bab45b8d88f6498d0176e5d8f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marcel=20M=C3=BCller?= Date: Wed, 10 Jul 2024 22:23:39 +0200 Subject: [PATCH] fix(theming): Don't reset the cachebuster value when we reset theming MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Marcel Müller --- apps/theming/lib/ThemingDefaults.php | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/apps/theming/lib/ThemingDefaults.php b/apps/theming/lib/ThemingDefaults.php index 1b31f91eeff5f..e564a29eb049f 100644 --- a/apps/theming/lib/ThemingDefaults.php +++ b/apps/theming/lib/ThemingDefaults.php @@ -437,7 +437,11 @@ public function set($setting, $value): void { * Revert all settings to the default value */ public function undoAll(): void { + // Remember the current cachebuster value, as we do not want to reset this value + // Otherwise this can lead to caching issues as the value might be known to a browser already + $cacheBusterKey = $this->config->getAppValue('theming', 'cachebuster', '0'); $this->config->deleteAppValues('theming'); + $this->config->setAppValue('theming', 'cachebuster', $cacheBusterKey); $this->increaseCacheBuster(); }