mirror of
https://github.com/phpbb/phpbb.git
synced 2025-07-27 04:18:55 +00:00
Compare commits
2 commits
c824854dc8
...
64edd460dd
Author | SHA1 | Date | |
---|---|---|---|
|
64edd460dd | ||
|
86195ac0f9 |
6 changed files with 8 additions and 10 deletions
|
@ -15,8 +15,8 @@ namespace phpbb\db\doctrine;
|
||||||
|
|
||||||
use Doctrine\DBAL\Platforms\AbstractPlatform;
|
use Doctrine\DBAL\Platforms\AbstractPlatform;
|
||||||
use Doctrine\DBAL\Types\Type;
|
use Doctrine\DBAL\Types\Type;
|
||||||
use phpbb\db\middleware\postgresql\platform as postgresql_platform;
|
|
||||||
use phpbb\db\middleware\oracle\platform as oracle_platform;
|
use phpbb\db\middleware\oracle\platform as oracle_platform;
|
||||||
|
use phpbb\db\middleware\postgresql\platform as postgresql_platform;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Case-insensitive string type (only supported by Postgres).
|
* Case-insensitive string type (only supported by Postgres).
|
||||||
|
|
|
@ -13,8 +13,6 @@
|
||||||
|
|
||||||
namespace phpbb\db\doctrine;
|
namespace phpbb\db\doctrine;
|
||||||
|
|
||||||
use InvalidArgumentException;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Helper class to generate Doctrine DBAL configuration.
|
* Helper class to generate Doctrine DBAL configuration.
|
||||||
*/
|
*/
|
||||||
|
@ -32,7 +30,7 @@ class connection_parameter_factory
|
||||||
*
|
*
|
||||||
* @return array Doctrine DBAL connection parameters.
|
* @return array Doctrine DBAL connection parameters.
|
||||||
*
|
*
|
||||||
* @throws InvalidArgumentException If a required parameter is empty or null.
|
* @throws \InvalidArgumentException If a required parameter is empty or null.
|
||||||
*/
|
*/
|
||||||
public static function get_configuration(
|
public static function get_configuration(
|
||||||
string $driver,
|
string $driver,
|
||||||
|
@ -68,7 +66,7 @@ class connection_parameter_factory
|
||||||
*
|
*
|
||||||
* @return array Doctrine's DBAL configuration for SQLite.
|
* @return array Doctrine's DBAL configuration for SQLite.
|
||||||
*
|
*
|
||||||
* @throws InvalidArgumentException If a required parameter is empty or null.
|
* @throws \InvalidArgumentException If a required parameter is empty or null.
|
||||||
*/
|
*/
|
||||||
private static function build_connection_parameters(
|
private static function build_connection_parameters(
|
||||||
array $params,
|
array $params,
|
||||||
|
@ -87,7 +85,7 @@ class connection_parameter_factory
|
||||||
|
|
||||||
if (empty($user) || empty($name))
|
if (empty($user) || empty($name))
|
||||||
{
|
{
|
||||||
throw new InvalidArgumentException('Required database parameter is not set.');
|
throw new \InvalidArgumentException('Required database parameter is not set.');
|
||||||
}
|
}
|
||||||
|
|
||||||
$params = array_merge($params, [
|
$params = array_merge($params, [
|
||||||
|
|
|
@ -13,8 +13,8 @@
|
||||||
|
|
||||||
namespace phpbb\db\middleware\mysql;
|
namespace phpbb\db\middleware\mysql;
|
||||||
|
|
||||||
use phpbb\db\middleware\mysql\driver as mysql_driver;
|
|
||||||
use Doctrine\DBAL\Driver;
|
use Doctrine\DBAL\Driver;
|
||||||
|
use phpbb\db\middleware\mysql\driver as mysql_driver;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* MySQL Doctrine middleware.
|
* MySQL Doctrine middleware.
|
||||||
|
|
|
@ -13,8 +13,8 @@
|
||||||
|
|
||||||
namespace phpbb\db\middleware\oracle;
|
namespace phpbb\db\middleware\oracle;
|
||||||
|
|
||||||
use phpbb\db\middleware\oracle\driver as oracle_driver;
|
|
||||||
use Doctrine\DBAL\Driver;
|
use Doctrine\DBAL\Driver;
|
||||||
|
use phpbb\db\middleware\oracle\driver as oracle_driver;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Oracle Doctrine middleware.
|
* Oracle Doctrine middleware.
|
||||||
|
|
|
@ -13,8 +13,8 @@
|
||||||
|
|
||||||
namespace phpbb\db\middleware\postgresql;
|
namespace phpbb\db\middleware\postgresql;
|
||||||
|
|
||||||
use phpbb\db\middleware\postgresql\driver as postgresql_driver;
|
|
||||||
use Doctrine\DBAL\Driver;
|
use Doctrine\DBAL\Driver;
|
||||||
|
use phpbb\db\middleware\postgresql\driver as postgresql_driver;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* PostgreSQL Doctrine middleware.
|
* PostgreSQL Doctrine middleware.
|
||||||
|
|
|
@ -13,8 +13,8 @@
|
||||||
|
|
||||||
namespace phpbb\db\middleware\sqlsrv;
|
namespace phpbb\db\middleware\sqlsrv;
|
||||||
|
|
||||||
use phpbb\db\middleware\sqlsrv\driver as sqlsrv_driver;
|
|
||||||
use Doctrine\DBAL\Driver;
|
use Doctrine\DBAL\Driver;
|
||||||
|
use phpbb\db\middleware\sqlsrv\driver as sqlsrv_driver;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Microsoft SQL server Doctrine middleware.
|
* Microsoft SQL server Doctrine middleware.
|
||||||
|
|
Loading…
Add table
Reference in a new issue