mirror of
https://github.com/nextcloud/server.git
synced 2026-02-13 15:54:59 -05:00
fix(appstoreFetcher): get app list from custom app store
Signed-off-by: Grigorii K. Shartsev <me@shgk.me>
This commit is contained in:
parent
07ce8c7e84
commit
23e8424c19
2 changed files with 1 additions and 8 deletions
|
|
@ -176,14 +176,6 @@ class AppFetcher extends Fetcher {
|
|||
public function get($allowUnstable = false): array {
|
||||
$allowPreReleases = $allowUnstable || $this->getChannel() === 'beta' || $this->getChannel() === 'daily' || $this->getChannel() === 'git';
|
||||
|
||||
$appStoreEnabled = $this->config->getSystemValueBool('appstoreenabled', true);
|
||||
$internetAvailable = $this->config->getSystemValueBool('has_internet_connection', true);
|
||||
|
||||
if (!$appStoreEnabled || !$internetAvailable) {
|
||||
$this->logger->info('AppStore is disabled or this instance has no Internet connection', ['app' => 'appstoreFetcher']);
|
||||
return [];
|
||||
}
|
||||
|
||||
$apps = parent::get($allowPreReleases);
|
||||
if (empty($apps)) {
|
||||
return [];
|
||||
|
|
|
|||
|
|
@ -145,6 +145,7 @@ abstract class Fetcher {
|
|||
$isDefaultAppStore = $this->config->getSystemValueString('appstoreurl', self::APP_STORE_URL) === self::APP_STORE_URL;
|
||||
|
||||
if (!$appstoreenabled || (!$internetavailable && $isDefaultAppStore)) {
|
||||
$this->logger->info('AppStore is disabled or this instance has no Internet connection to access the default app store', ['app' => 'appstoreFetcher']);
|
||||
return [];
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue