From 1992d11d7da6c43fd194931453f11b1b56e8a2f4 Mon Sep 17 00:00:00 2001 From: Jakub Onderka Date: Wed, 10 Mar 2021 16:11:14 +0100 Subject: [PATCH] Fix warning in AppFetcher.php when appstore is disabled Signed-off-by: Jakub Onderka --- lib/private/App/AppStore/Fetcher/AppFetcher.php | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/lib/private/App/AppStore/Fetcher/AppFetcher.php b/lib/private/App/AppStore/Fetcher/AppFetcher.php index 4dc517879e..416e55463c 100644 --- a/lib/private/App/AppStore/Fetcher/AppFetcher.php +++ b/lib/private/App/AppStore/Fetcher/AppFetcher.php @@ -86,6 +86,10 @@ class AppFetcher extends Fetcher { protected function fetch($ETag, $content, $allowUnstable = false) { /** @var mixed[] $response */ $response = parent::fetch($ETag, $content); + + if (empty($response)) { + return []; + } $allowPreReleases = $allowUnstable || $this->getChannel() === 'beta' || $this->getChannel() === 'daily'; $allowNightly = $allowUnstable || $this->getChannel() === 'daily';