diff options
Diffstat (limited to 'lib/appconfig.php')
-rw-r--r-- | lib/appconfig.php | 27 |
1 files changed, 27 insertions, 0 deletions
diff --git a/lib/appconfig.php b/lib/appconfig.php index 47b20b6..1562a17 100644 --- a/lib/appconfig.php +++ b/lib/appconfig.php @@ -299,6 +299,13 @@ class AppConfig { public $_customizationMacros = "customization_macros"; /** + * The config key for the plugins + * + * @var string + */ + public $_customizationPlugins = "customization_plugins"; + + /** * @param string $AppName - application name */ public function __construct($AppName) { @@ -1179,6 +1186,26 @@ class AppConfig { } /** + * Save plugins setting + * + * @param bool $value - enable macros + */ + public function SetCustomizationPlugins($value) { + $this->logger->info("Set plugins enabled: " . json_encode($value), ["app" => $this->appName]); + + $this->config->setAppValue($this->appName, $this->_customizationPlugins, json_encode($value)); + } + + /** + * Get plugins setting + * + * @return bool + */ + public function GetCustomizationPlugins() { + return $this->config->getAppValue($this->appName, $this->_customizationPlugins, "true") === "true"; + } + + /** * Additional data about formats * * @var array |