Merge pull request #46555 from nextcloud/emptyArrayAppStoreFail

fix(appstore): Return an empty array in case of fail
pull/46378/head
Git'Fellow 2024-07-17 12:33:33 +07:00 committed by GitHub
commit b06ce832d8
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 4 additions and 0 deletions

@ -153,6 +153,10 @@ class AppFetcher extends Fetcher {
$allowPreReleases = $allowUnstable || $this->getChannel() === 'beta' || $this->getChannel() === 'daily' || $this->getChannel() === 'git';
$apps = parent::get($allowPreReleases);
if (empty($apps)) {
$this->logger->warning('Could not get apps from the appstore', ['app' => 'appstoreFetcher']);
return [];
}
$allowList = $this->config->getSystemValue('appsallowlist');
// If the admin specified a allow list, filter apps from the appstore