From 5248f0533eb5f47a87d7796a744f676dc761e915 Mon Sep 17 00:00:00 2001 From: Felix Hahn Date: Mon, 27 Nov 2023 14:05:34 +0100 Subject: [PATCH] fix module enabling (vars in database) --- Module.php | 15 ++++++--------- 1 file changed, 6 insertions(+), 9 deletions(-) diff --git a/Module.php b/Module.php index 247b213..c913807 100644 --- a/Module.php +++ b/Module.php @@ -33,21 +33,18 @@ public function enable() { return false; } - private function enableTheme() { - + private function enableTheme() + { + // Save special colors (lightened, darkened, faded colors), create theme files etc. + $model = new ColorSettings(); + $model->save(); + // see https://community.humhub.com/s/module-development/wiki/Theme+Modules $theme = ThemeHelper::getThemeByName(self::FLEX_THEME_NAME); if ($theme !== null) { $theme->activate(); DynamicConfig::rewrite(); } - - // Save special colors (lightened, darkened, faded colors) - $model = new ColorSettings(); - $model->saveSpecialColors(); - - // Create theme.css - FileHelper::updateThemeFile(); } // Module Deactivation