Merge pull request #951 from keriati/fix/950-env-db

fix: change how database type is checked #950
This commit is contained in:
KodeStar 2022-11-14 09:57:49 +00:00 committed by GitHub
commit d4f7ad842c
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -123,7 +123,7 @@ class AppServiceProvider extends ServiceProvider
*/
public function setupDatabase(): void
{
$db_type = env('DB_CONNECTION');
$db_type = config()->get('database.default');
if ($db_type == 'sqlite' && ! is_file(database_path('app.sqlite'))) {
touch(database_path('app.sqlite'));