1
0
mirror of https://github.com/phpbb/phpbb.git synced 2025-07-30 21:40:43 +02:00

[ticket/14957] Do not cache database config entries

PHPBB3-14957
This commit is contained in:
Marc Alexander
2016-12-28 18:15:17 +01:00
parent bc96a9f1f6
commit 14fd750b08
6 changed files with 21 additions and 10 deletions

View File

@@ -185,6 +185,7 @@ class container_builder
}
$this->container->set('config.php', $this->config_php_file);
$this->inject_dbal_driver();
if ($this->compile_container)
{
@@ -303,6 +304,17 @@ class container_builder
}
}
/**
* Inject the dbal connection driver into container
*/
protected function inject_dbal_driver()
{
if (!empty($this->config_php_file->get_all()))
{
$this->container->set('dbal.conn.driver', $this->get_dbal_connection());
}
}
/**
* Get DB connection.
*
@@ -320,6 +332,7 @@ class container_builder
$this->config_php_file->get('dbpasswd'),
$this->config_php_file->get('dbname'),
$this->config_php_file->get('dbport'),
false,
defined('PHPBB_DB_NEW_LINK') && PHPBB_DB_NEW_LINK
);
}