mirror of
https://codeberg.org/vlw/scaffold.git
synced 2026-02-26 11:31:57 +01:00
fix: database as optional parameter for set_credentials (#25)
This is another follow-up PR for #22 which fixes a deprecation issue about defining optional parameters that are then called as named. ```php Database::set_credentials("db"); ``` ``` vlw\Scaffold\Database::set_credentials(): Optional parameter $host declared before required parameter $database is implicitly treated as a required parameter ``` Reviewed-on: https://codeberg.org/vlw/scaffold/pulls/25
This commit is contained in:
parent
f4b8f8673e
commit
8a04cab4b5
1 changed files with 1 additions and 1 deletions
|
|
@ -32,7 +32,7 @@
|
||||||
?string $host = self::DEFAULT_HOSTNAME,
|
?string $host = self::DEFAULT_HOSTNAME,
|
||||||
?string $username = self::DEFAULT_USERNAME,
|
?string $username = self::DEFAULT_USERNAME,
|
||||||
?string $password = self::DEFAULT_PASSWORD,
|
?string $password = self::DEFAULT_PASSWORD,
|
||||||
string $database
|
?string $database = ""
|
||||||
) {
|
) {
|
||||||
// Create key if it does not exist
|
// Create key if it does not exist
|
||||||
if (!$_ENV["mariadb"]) {
|
if (!$_ENV["mariadb"]) {
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue