close #325 added support for sqlite3 + give credits to @santilin

This commit is contained in:
tonydspaniard
2019-06-28 23:49:06 +02:00
parent fc326d0a61
commit 94dab4b28b
2 changed files with 13 additions and 4 deletions

View File

@ -3,6 +3,8 @@
- Fix #316: Fix new response from Google OAuth Api (Julian-B90)
- Fix #321: Fix new response from LinkedIn OAuth Api (tonydspaniard)
- Fix #322: Fix boolean values in migrations for SQL server (tsdogs)
- Enh #325: Added support for sqlite3 (santilin)
- Fix #326: Fix rule for the user auth_tf_enabled field (santilin)
## 1.5.0 April 19, 2019
- Fix: Fix condition in EmailChangeService (it was always false) (borisaeric)

View File

@ -31,6 +31,7 @@ class MigrationHelper
case 'dblib':
case 'mssql':
case 'sqlsrv':
case 'sqlite':
return null;
default:
throw new RuntimeException('Your database is not supported!');
@ -48,8 +49,8 @@ class MigrationHelper
{
switch ($driverName) {
case 'mysql':
return $driverName;
case 'pgsql':
case 'sqlite':
return $driverName;
case 'dblib':
case 'mssql':
@ -72,6 +73,12 @@ class MigrationHelper
return self::resolveDbType($driverName) === 'sqlsrv';
}
/**
* @param $driverName
* @param bool $value
*
* @return bool|int
*/
public static function getBooleanValue($driverName, $value = false)
{
if (self::isMicrosoftSQLServer($driverName)) {