summaryrefslogtreecommitdiffstats
path: root/lib/private/legacy
diff options
context:
space:
mode:
authorMorris Jobke <hey@morrisjobke.de>2018-02-17 15:25:24 +0100
committerMorris Jobke <hey@morrisjobke.de>2018-02-17 16:05:13 +0100
commit9dc3b0480228a3c35b3b7a7cb1a904006f7e0762 (patch)
treed432bd59aa7d4b87c14835b29973a0e829370e5c /lib/private/legacy
parentedee243b27f7d042998fd840d0b0f75548e3c489 (diff)
downloadnextcloud-server-9dc3b0480228a3c35b3b7a7cb1a904006f7e0762.tar.gz
nextcloud-server-9dc3b0480228a3c35b3b7a7cb1a904006f7e0762.zip
Fix app version to be always string and neither array nor null
Signed-off-by: Morris Jobke <hey@morrisjobke.de>
Diffstat (limited to 'lib/private/legacy')
-rw-r--r--lib/private/legacy/app.php6
1 files changed, 1 insertions, 5 deletions
diff --git a/lib/private/legacy/app.php b/lib/private/legacy/app.php
index f04310041ac..40af10f36fc 100644
--- a/lib/private/legacy/app.php
+++ b/lib/private/legacy/app.php
@@ -856,7 +856,7 @@ class OC_App {
*
* @return boolean true if compatible, otherwise false
*/
- public static function isAppCompatible($ocVersion, $appInfo) {
+ public static function isAppCompatible(string $ocVersion, array $appInfo): bool {
$requireMin = '';
$requireMax = '';
if (isset($appInfo['dependencies']['nextcloud']['@attributes']['min-version'])) {
@@ -877,10 +877,6 @@ class OC_App {
$requireMax = $appInfo['requiremax'];
}
- if (is_array($ocVersion)) {
- $ocVersion = implode('.', $ocVersion);
- }
-
if (!empty($requireMin)
&& version_compare(self::adjustVersionParts($ocVersion, $requireMin), $requireMin, '<')
) {