diff options
-rw-r--r-- | phpBB/phpbb/config_php_file.php | 6 | ||||
-rw-r--r-- | tests/di/fixtures/config.php | 2 |
2 files changed, 7 insertions, 1 deletions
diff --git a/phpBB/phpbb/config_php_file.php b/phpBB/phpbb/config_php_file.php index 7445e7df22..e3f7357720 100644 --- a/phpBB/phpbb/config_php_file.php +++ b/phpBB/phpbb/config_php_file.php @@ -155,6 +155,12 @@ class config_php_file return $dbms; } + // Force use of mysqli when specifying mysql + if (preg_match('/(phpbb\\\db\\\driver\\\)?mysql$/i', $dbms)) + { + return 'phpbb\db\driver\mysqli'; + } + throw new \RuntimeException("You have specified an invalid dbms driver: $dbms"); } } diff --git a/tests/di/fixtures/config.php b/tests/di/fixtures/config.php index d6b8a567c7..1e9207d924 100644 --- a/tests/di/fixtures/config.php +++ b/tests/di/fixtures/config.php @@ -1,7 +1,7 @@ <?php // phpBB 3.1.x auto-generated configuration file // Do not change anything in this file! -$dbms = 'mysqli'; +$dbms = 'mysql'; $dbhost = '127.0.0.1'; $dbport = ''; $dbname = 'phpbb'; |