Commit f4fb2d79 authored by totten's avatar totten

CRM-16373 - Simplify loading of enableComponents

parent b391b97b
......@@ -101,6 +101,7 @@ class CRM_Admin_Form_Setting extends CRM_Core_Form {
$this->_defaults['enableSSL'] = CRM_Core_BAO_Setting::getItem(CRM_Core_BAO_Setting::SYSTEM_PREFERENCES_NAME, 'enableSSL');
$this->_defaults['verifySSL'] = CRM_Core_BAO_Setting::getItem(CRM_Core_BAO_Setting::SYSTEM_PREFERENCES_NAME, 'verifySSL');
$this->_defaults['enableComponents'] = Civi::settings()->get('enable_components');
}
return $this->_defaults;
......
......@@ -310,15 +310,6 @@ class CRM_Core_BAO_ConfigSetting {
mb_internal_encoding('UTF-8');
}
}
// dont add if its empty
if (!empty($defaults)) {
// Pickup enabled-components from settings table if found.
$enableComponents = Civi::settings()->get('enable_components');
if (!empty($enableComponents)) {
$defaults['enableComponents'] = $enableComponents;
}
}
}
/**
......
......@@ -288,6 +288,8 @@ class CRM_Core_Config extends CRM_Core_Config_Variables {
$this->$key = $value;
}
$this->enableComponents = Civi::settings()->get('enable_components');
$this->customFileUploadDir = CRM_Core_Config_Defaults::getCustomFileUploadDir();
$this->customPHPPathDir = CRM_Core_Config_Defaults::getCustomPhpPathDir();
$this->customTemplateDir = CRM_Core_Config_Defaults::getCustomTemplateDir();
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment