From 79872aa1f9d23c3cd9996e07bc30480aa3491e6f Mon Sep 17 00:00:00 2001 From: Alexander Ebert Date: Wed, 18 Oct 2023 18:43:46 +0200 Subject: [PATCH] Enforce sane values for the theme color --- wcfsetup/install/files/lib/data/style/Style.class.php | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/wcfsetup/install/files/lib/data/style/Style.class.php b/wcfsetup/install/files/lib/data/style/Style.class.php index a9349f8d82..91dda8b291 100644 --- a/wcfsetup/install/files/lib/data/style/Style.class.php +++ b/wcfsetup/install/files/lib/data/style/Style.class.php @@ -214,11 +214,9 @@ class Style extends DatabaseObject } } - // see https://github.com/WoltLab/WCF/issues/2636 - if (empty($this->variables['wcfPageThemeColor'])) { - $this->variables['wcfPageThemeColor'] = $this->variables['wcfHeaderBackground']; - } - if ($this->hasDarkMode && empty($this->variables[self::DARK_MODE_PREFIX . 'wcfPageThemeColor'])) { + // The theme color implicitly matches the header background color. + $this->variables['wcfPageThemeColor'] = $this->variables['wcfHeaderBackground']; + if ($this->hasDarkMode) { $this->variables[self::DARK_MODE_PREFIX . 'wcfPageThemeColor'] = $this->variables[self::DARK_MODE_PREFIX . 'wcfHeaderBackground']; } -- 2.20.1