diff options
author | Julien Veyssier <eneiluj@posteo.net> | 2021-10-21 12:42:14 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-10-21 12:42:14 +0200 |
commit | 0bef570fe9d06d97e5c9d05b689de26a06366e69 (patch) | |
tree | 8853baf849cd0b5cf07feb03b9c7519e88ba8672 /apps | |
parent | c5405befcfeb5dcc0d8cce85d5ea8466fed3c268 (diff) | |
parent | f24e8212c383e74261a42d1fcf88a81bde2ed5e8 (diff) | |
download | nextcloud-server-0bef570fe9d06d97e5c9d05b689de26a06366e69.tar.gz nextcloud-server-0bef570fe9d06d97e5c9d05b689de26a06366e69.zip |
Merge pull request #29256 from nextcloud/fix/noid/harmonize-appstoreenabled-check
Fix appstoreenabled check
Diffstat (limited to 'apps')
-rw-r--r-- | apps/settings/lib/Controller/AppSettingsController.php | 2 | ||||
-rw-r--r-- | apps/settings/tests/Controller/AppSettingsControllerTest.php | 4 |
2 files changed, 3 insertions, 3 deletions
diff --git a/apps/settings/lib/Controller/AppSettingsController.php b/apps/settings/lib/Controller/AppSettingsController.php index 5ed25ec2e2a..8dbe9fb2f07 100644 --- a/apps/settings/lib/Controller/AppSettingsController.php +++ b/apps/settings/lib/Controller/AppSettingsController.php @@ -131,7 +131,7 @@ class AppSettingsController extends Controller { public function viewApps(): TemplateResponse { \OC_Util::addScript('settings', 'apps'); $params = []; - $params['appstoreEnabled'] = $this->config->getSystemValue('appstoreenabled', true) === true; + $params['appstoreEnabled'] = $this->config->getSystemValueBool('appstoreenabled', true); $params['updateCount'] = count($this->getAppsWithUpdates()); $params['developerDocumentation'] = $this->urlGenerator->linkToDocs('developer-manual'); $params['bundles'] = $this->getBundles(); diff --git a/apps/settings/tests/Controller/AppSettingsControllerTest.php b/apps/settings/tests/Controller/AppSettingsControllerTest.php index e273375d76d..28d77dc3696 100644 --- a/apps/settings/tests/Controller/AppSettingsControllerTest.php +++ b/apps/settings/tests/Controller/AppSettingsControllerTest.php @@ -190,7 +190,7 @@ class AppSettingsControllerTest extends TestCase { ->willReturn(false); $this->config ->expects($this->once()) - ->method('getSystemValue') + ->method('getSystemValueBool') ->with('appstoreenabled', true) ->willReturn(true); $this->navigationManager @@ -224,7 +224,7 @@ class AppSettingsControllerTest extends TestCase { $this->bundleFetcher->expects($this->once())->method('getBundles')->willReturn([]); $this->config ->expects($this->once()) - ->method('getSystemValue') + ->method('getSystemValueBool') ->with('appstoreenabled', true) ->willReturn(false); $this->navigationManager |