diff --git a/models/AdvancedSettings.php b/models/AdvancedSettings.php index a47be98..dc4a465 100644 --- a/models/AdvancedSettings.php +++ b/models/AdvancedSettings.php @@ -66,7 +66,7 @@ protected function getSettingsArray() $module = Yii::$app->getModule('flex-theme'); // Get base settings - $config_names = ['commentLink', 'likeLink', 'likeIcon', 'likeIconFull', 'likeIconColor']; + $config_names = Config::CONFIG_NAMES; foreach( $config_names as $setting) { $value = $module->settings->get($setting); diff --git a/models/Config.php b/models/Config.php index ed20b32..01c2f02 100644 --- a/models/Config.php +++ b/models/Config.php @@ -16,6 +16,7 @@ class Config extends \yii\base\Model { // Module settings + const CONFIG_NAMES = ['commentLink', 'likeLink', 'likeIcon', 'likeIconFull', 'likeIconColor', 'showTopicMenu', 'showUploadAsButtons']; public $commentLink; public $likeLink; public $likeIcon;