From bde109d1581bd9fcdc64fe65796f8b610740059e Mon Sep 17 00:00:00 2001 From: Joas Schilling Date: Wed, 1 Feb 2023 21:39:49 +0100 Subject: [PATCH] fix(updater): Don't warn about missing appstore updates for apps deployed from git Signed-off-by: Joas Schilling --- apps/updatenotification/lib/Controller/APIController.php | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/apps/updatenotification/lib/Controller/APIController.php b/apps/updatenotification/lib/Controller/APIController.php index 75b847aceb3fb..26657eb66f0b8 100644 --- a/apps/updatenotification/lib/Controller/APIController.php +++ b/apps/updatenotification/lib/Controller/APIController.php @@ -130,6 +130,15 @@ public function getAppList(string $newVersion): DataResponse { $this->language = $this->l10nFactory->getUserLanguage($this->userSession->getUser()); + // Ignore apps that are deployed from git + $installedApps = array_filter($installedApps, function(string $appId) { + try { + return !file_exists($this->appManager->getAppPath($appId) . '/.git'); + } catch (AppPathNotFoundException $e) { + return true; + } + }); + $missing = array_diff($installedApps, $availableApps); $missing = array_map([$this, 'getAppDetails'], $missing); sort($missing);