diff options
Diffstat (limited to 'core/Settings/Storage/Factory.php')
-rw-r--r-- | core/Settings/Storage/Factory.php | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/core/Settings/Storage/Factory.php b/core/Settings/Storage/Factory.php index 5c1c6ca645..a64a9353d3 100644 --- a/core/Settings/Storage/Factory.php +++ b/core/Settings/Storage/Factory.php @@ -45,6 +45,21 @@ class Factory } /** + * @param string $section + * @return mixed + */ + public function getConfigStorage($section) + { + $id = 'config' . $section; + if (!isset($this->cache[$id])) { + $backend = new Backend\Config($section); + $this->cache[$id] = $this->makeStorage($backend); + } + + return $this->cache[$id]; + } + + /** * Get a storage instance for measurable settings. * * The storage will hold values that belong to the given idSite and plugin name. Be aware that a storage instance |