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/App | |
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/App')
-rw-r--r-- | lib/private/App/AppManager.php | 2 | ||||
-rw-r--r-- | lib/private/App/DependencyAnalyzer.php | 8 | ||||
-rw-r--r-- | lib/private/App/PlatformRepository.php | 4 |
3 files changed, 7 insertions, 7 deletions
diff --git a/lib/private/App/AppManager.php b/lib/private/App/AppManager.php index 937cc511985..1fcf4e8281f 100644 --- a/lib/private/App/AppManager.php +++ b/lib/private/App/AppManager.php @@ -540,7 +540,7 @@ class AppManager implements IAppManager { */ public function getIncompatibleApps(string $version): array { $apps = $this->getInstalledApps(); - $incompatibleApps = array(); + $incompatibleApps = []; foreach ($apps as $appId) { $info = $this->getAppInfo($appId); if ($info === null) { diff --git a/lib/private/App/DependencyAnalyzer.php b/lib/private/App/DependencyAnalyzer.php index a59e8c21735..81ae6e7a168 100644 --- a/lib/private/App/DependencyAnalyzer.php +++ b/lib/private/App/DependencyAnalyzer.php @@ -188,7 +188,7 @@ class DependencyAnalyzer { return $missing; } if (!is_array($supportedDatabases)) { - $supportedDatabases = array($supportedDatabases); + $supportedDatabases = [$supportedDatabases]; } $supportedDatabases = array_map(function ($db) { return $this->getValue($db); @@ -212,7 +212,7 @@ class DependencyAnalyzer { $commands = $dependencies['command']; if (!is_array($commands)) { - $commands = array($commands); + $commands = [$commands]; } if (isset($commands['@value'])) { $commands = [$commands]; @@ -242,7 +242,7 @@ class DependencyAnalyzer { $libs = $dependencies['lib']; if (!is_array($libs)) { - $libs = array($libs); + $libs = [$libs]; } if (isset($libs['@value'])) { $libs = [$libs]; @@ -294,7 +294,7 @@ class DependencyAnalyzer { return $this->getValue($os); }, $oss); } else { - $oss = array($oss); + $oss = [$oss]; } $currentOS = $this->platform->getOS(); if (!in_array($currentOS, $oss)) { diff --git a/lib/private/App/PlatformRepository.php b/lib/private/App/PlatformRepository.php index c285554ae1c..61def8ff434 100644 --- a/lib/private/App/PlatformRepository.php +++ b/lib/private/App/PlatformRepository.php @@ -38,11 +38,11 @@ class PlatformRepository { protected function initialize() { $loadedExtensions = get_loaded_extensions(); - $packages = array(); + $packages = []; // Extensions scanning foreach ($loadedExtensions as $name) { - if (in_array($name, array('standard', 'Core'))) { + if (in_array($name, ['standard', 'Core'])) { continue; } |