summaryrefslogtreecommitdiffstats
path: root/settings
diff options
context:
space:
mode:
authorRoeland Jago Douma <roeland@famdouma.nl>2016-12-09 22:03:58 +0100
committerRoeland Jago Douma <roeland@famdouma.nl>2016-12-09 22:30:54 +0100
commitd59ffb8bf121b326fe7dd5b67103db306bd0a3ae (patch)
treecbf251823108a3fa35a2841f6018b67e4113dff2 /settings
parent0de83a3a0189a96338abd0345b70c89bc543bf49 (diff)
downloadnextcloud-server-d59ffb8bf121b326fe7dd5b67103db306bd0a3ae.tar.gz
nextcloud-server-d59ffb8bf121b326fe7dd5b67103db306bd0a3ae.zip
Check for app updates on disabled page
Fixes #2403 We need to check for updates of disabled apps so that if you update with incompatible apps you at least get a chance to upgrade. Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
Diffstat (limited to 'settings')
-rw-r--r--settings/Controller/AppSettingsController.php9
1 files changed, 9 insertions, 0 deletions
diff --git a/settings/Controller/AppSettingsController.php b/settings/Controller/AppSettingsController.php
index fe050332fc8..6a5b5210c0f 100644
--- a/settings/Controller/AppSettingsController.php
+++ b/settings/Controller/AppSettingsController.php
@@ -296,6 +296,15 @@ class AppSettingsController extends Controller {
$apps = array_filter($apps, function ($app) {
return !$app['active'];
});
+
+ $apps = array_map(function ($app) {
+ $newVersion = \OC\Installer::isUpdateAvailable($app['id'], $this->appFetcher);
+ if ($newVersion !== false) {
+ $app['update'] = $newVersion;
+ }
+ return $app;
+ }, $apps);
+
usort($apps, function ($a, $b) {
$a = (string)$a['name'];
$b = (string)$b['name'];