Merge pull request #2598 from nextcloud/fix_2403

Check for app updates on disabled page
This commit is contained in:
Lukas Reschke 2016-12-10 12:21:20 +01:00 committed by GitHub
commit aedd1fc9a0
1 changed files with 9 additions and 0 deletions

View File

@ -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'];