Add (bool) type casts to all boolean env() calls across config files

This commit is contained in:
root
2026-05-26 16:40:52 +02:00
parent f5c21e36f1
commit 93e6f6a273
5 changed files with 8 additions and 8 deletions
+2 -2
View File
@@ -9,7 +9,7 @@ return [
/* /*
* If set to false, no activities will be saved to the database. * If set to false, no activities will be saved to the database.
*/ */
'enabled' => env('ACTIVITYLOG_ENABLED', true), 'enabled' => (bool) env('ACTIVITYLOG_ENABLED', true),
/* /*
* When the clean command is executed, all recording activities older than * When the clean command is executed, all recording activities older than
@@ -59,7 +59,7 @@ return [
* buffer is flushed. * buffer is flushed.
*/ */
'buffer' => [ 'buffer' => [
'enabled' => env('ACTIVITYLOG_BUFFER_ENABLED', false), 'enabled' => (bool) env('ACTIVITYLOG_BUFFER_ENABLED', false),
], ],
/* /*
+3 -3
View File
@@ -37,7 +37,7 @@ return [
'url' => env('DB_URL'), 'url' => env('DB_URL'),
'database' => env('DB_DATABASE', database_path('database.sqlite')), 'database' => env('DB_DATABASE', database_path('database.sqlite')),
'prefix' => '', 'prefix' => '',
'foreign_key_constraints' => env('DB_FOREIGN_KEYS', true), 'foreign_key_constraints' => (bool) env('DB_FOREIGN_KEYS', true),
], ],
'mysql' => [ 'mysql' => [
@@ -159,7 +159,7 @@ return [
'port' => env('REDIS_PORT', '6379'), 'port' => env('REDIS_PORT', '6379'),
'database' => env('DB_REDIS_DB', '0'), 'database' => env('DB_REDIS_DB', '0'),
'read_timeout' => env('REDIS_READ_TIMEOUT', 1.0), 'read_timeout' => env('REDIS_READ_TIMEOUT', 1.0),
'persistent' => env('REDIS_PERSISTENT', true), 'persistent' => (bool) env('REDIS_PERSISTENT', true),
], ],
'cache' => [ 'cache' => [
@@ -170,7 +170,7 @@ return [
'port' => env('REDIS_PORT', '6379'), 'port' => env('REDIS_PORT', '6379'),
'database' => env('REDIS_CACHE_DB', '1'), 'database' => env('REDIS_CACHE_DB', '1'),
'read_timeout' => env('REDIS_READ_TIMEOUT', 1.0), 'read_timeout' => env('REDIS_READ_TIMEOUT', 1.0),
'persistent' => env('REDIS_PERSISTENT', true), 'persistent' => (bool) env('REDIS_PERSISTENT', true),
], ],
], ],
+1 -1
View File
@@ -38,7 +38,7 @@ return [
'bucket' => env('AWS_BUCKET'), 'bucket' => env('AWS_BUCKET'),
'url' => env('AWS_URL'), 'url' => env('AWS_URL'),
'endpoint' => env('AWS_ENDPOINT'), 'endpoint' => env('AWS_ENDPOINT'),
'use_path_style_endpoint' => env('AWS_USE_PATH_STYLE_ENDPOINT', false), 'use_path_style_endpoint' => (bool) env('AWS_USE_PATH_STYLE_ENDPOINT', false),
'throw' => false, 'throw' => false,
], ],
], ],
+1 -1
View File
@@ -16,7 +16,7 @@ return [
| |
*/ */
'enabled' => env('LOG_VIEWER_ENABLED', true), 'enabled' => (bool) env('LOG_VIEWER_ENABLED', true),
'require_auth_in_production' => true, 'require_auth_in_production' => true,
+1 -1
View File
@@ -46,7 +46,7 @@ return [
| |
*/ */
'encrypt' => env('SESSION_ENCRYPT', true), 'encrypt' => (bool) env('SESSION_ENCRYPT', true),
/* /*
|-------------------------------------------------------------------------- |--------------------------------------------------------------------------