aboutsummaryrefslogtreecommitdiffstats
path: root/phpBB/phpbb/di
diff options
context:
space:
mode:
Diffstat (limited to 'phpBB/phpbb/di')
-rw-r--r--phpBB/phpbb/di/container_builder.php16
1 files changed, 16 insertions, 0 deletions
diff --git a/phpBB/phpbb/di/container_builder.php b/phpBB/phpbb/di/container_builder.php
index 5ad9336695..6216dad978 100644
--- a/phpBB/phpbb/di/container_builder.php
+++ b/phpBB/phpbb/di/container_builder.php
@@ -195,6 +195,8 @@ class container_builder
$loader = new YamlFileLoader($this->container, new FileLocator(phpbb_realpath($this->get_config_path())));
$loader->load(PHPBB_ENVIRONMENT . '/config.yml');
+ $this->inject_custom_parameters();
+
if ($this->compile_container)
{
$this->container->compile();
@@ -431,6 +433,20 @@ class container_builder
}
/**
+ * Inject the customs parameters into the container
+ */
+ protected function inject_custom_parameters()
+ {
+ if ($this->custom_parameters !== null)
+ {
+ foreach ($this->custom_parameters as $key => $value)
+ {
+ $this->container->setParameter($key, $value);
+ }
+ }
+ }
+
+ /**
* Returns the core parameters.
*
* @return array An array of core parameters