diff options
Diffstat (limited to 'core/Db/Adapter.php')
-rw-r--r-- | core/Db/Adapter.php | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/core/Db/Adapter.php b/core/Db/Adapter.php index 4e245c84d3..bea69e1d04 100644 --- a/core/Db/Adapter.php +++ b/core/Db/Adapter.php @@ -39,7 +39,13 @@ class Adapter $className = self::getAdapterClassName($adapterName); - $adapter = new $className($dbInfos); + // make sure not to pass any references otherwise they will modify $dbInfos + $infos = array(); + foreach ($dbInfos as $key => $val) { + $infos[$key] = $val; + } + + $adapter = new $className($infos); if ($connect) { $adapter->getConnection(); |