Skip to content

Commit 8d13e86

Browse files
committed
Added parenthesis around port config before the integer type cast to stop error if $config['port'] not set
1 parent 3d5eb29 commit 8d13e86

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/Bootstrap/CreateDatabaseConnection.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ public function bootstrap(Application $app)
2424
'driver' => 'mysql',
2525
'url' => '',
2626
'host' => $config['hostname'] ?? env('DB_HOST', '127.0.0.1'),
27-
'port' => (int) $config['port'] ?? env('DB_PORT', 3306),
27+
'port' => (int) ($config['port'] ?? env('DB_PORT', 3306)),
2828
'database' => $config['database'] ?? env('EE_DB_DATABASE', 'expressionengine'),
2929
'username' => $config['username'] ?? env('DB_USERNAME', 'forge'),
3030
'password' => $config['password'] ?? env('DB_PASSWORD', ''),

0 commit comments

Comments
 (0)