diff options
author | Christoph Wurst <christoph@winzerhof-wurst.at> | 2020-03-26 09:30:18 +0100 |
---|---|---|
committer | Christoph Wurst <christoph@winzerhof-wurst.at> | 2020-03-26 16:34:56 +0100 |
commit | b80ebc96748b45fd2e0ba9323308657c4b00b7ec (patch) | |
tree | ec20e0ffa2f86b9b54939a83a785407319f94559 /lib/private/Setup.php | |
parent | 62403d0932be7d620c7bdadc6b4e13eb496fcd6f (diff) | |
download | nextcloud-server-b80ebc96748b45fd2e0ba9323308657c4b00b7ec.tar.gz nextcloud-server-b80ebc96748b45fd2e0ba9323308657c4b00b7ec.zip |
Use the short array syntax, everywhere
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
Diffstat (limited to 'lib/private/Setup.php')
-rw-r--r-- | lib/private/Setup.php | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/lib/private/Setup.php b/lib/private/Setup.php index 26299aaa039..4042d502a7e 100644 --- a/lib/private/Setup.php +++ b/lib/private/Setup.php @@ -182,7 +182,7 @@ class Setup { throw new Exception('Supported databases are not properly configured.'); } - $supportedDatabases = array(); + $supportedDatabases = []; foreach ($configuredDatabases as $database) { if (array_key_exists($database, $availableDatabases)) { @@ -263,7 +263,7 @@ class Setup { ]; } - return array( + return [ 'hasSQLite' => isset($databases['sqlite']), 'hasMySQL' => isset($databases['mysql']), 'hasPostgreSQL' => isset($databases['pgsql']), @@ -272,7 +272,7 @@ class Setup { 'directory' => $dataDir, 'htaccessWorking' => $htAccessWorking, 'errors' => $errors, - ); + ]; } /** @@ -282,7 +282,7 @@ class Setup { public function install($options) { $l = $this->l10n; - $error = array(); + $error = []; $dbType = $options['dbtype']; if (empty($options['adminlogin'])) { @@ -310,7 +310,7 @@ class Setup { // validate the data directory if ((!is_dir($dataDir) && !mkdir($dataDir)) || !is_writable($dataDir)) { - $error[] = $l->t("Can't create or write into the data directory %s", array($dataDir)); + $error[] = $l->t("Can't create or write into the data directory %s", [$dataDir]); } if (!empty($error)) { |