summaryrefslogtreecommitdiffstats
path: root/lib/private/app.php
diff options
context:
space:
mode:
Diffstat (limited to 'lib/private/app.php')
-rw-r--r--lib/private/app.php10
1 files changed, 5 insertions, 5 deletions
diff --git a/lib/private/app.php b/lib/private/app.php
index 1a242ad968e..6f45b6e6dd7 100644
--- a/lib/private/app.php
+++ b/lib/private/app.php
@@ -770,12 +770,12 @@ class OC_App{
}
// prio 2: shipped
- if ($a['shipped'] != $b['shipped']) {
- $atemp = ($a['shipped'] == true ? 1 : 0);
- $btemp = ($b['shipped'] == true ? 1 : 0);
- return ($btemp - $atemp);
+ $ashipped = (array_key_exists('shipped', $a) && $a['shipped'] === 'true') ? 1 : 0;
+ $bshipped = (array_key_exists('shipped', $b) && $b['shipped'] === 'true') ? 1 : 0;
+ if ($ashipped !== $bshipped) {
+ return ($bshipped - $ashipped);
}
-
+
// prio 3: recommended
if ($a['internalclass'] != $b['internalclass']) {
$atemp = ($a['internalclass'] == 'recommendedapp' ? 1 : 0);