summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLukas Reschke <lukas@statuscode.ch>2017-04-19 17:01:27 +0200
committerGitHub <noreply@github.com>2017-04-19 17:01:27 +0200
commite91b8b452ca5861ba9144842a98d68deedad34a3 (patch)
tree079316014c121135dc28b82d3e1f9a5e07df0f3c
parenta3569a14524f6f669bc9dc868658794ded12776a (diff)
parentbe30ff59ef7bc9ac3ed71974373081763f0f2ec9 (diff)
downloadnextcloud-server-e91b8b452ca5861ba9144842a98d68deedad34a3.tar.gz
nextcloud-server-e91b8b452ca5861ba9144842a98d68deedad34a3.zip
Merge pull request #4395 from nextcloud/fix_4394
Do not show empty admin sections
-rw-r--r--settings/Controller/AdminSettingsController.php4
1 files changed, 4 insertions, 0 deletions
diff --git a/settings/Controller/AdminSettingsController.php b/settings/Controller/AdminSettingsController.php
index 4bc986e708e..6c915be6f94 100644
--- a/settings/Controller/AdminSettingsController.php
+++ b/settings/Controller/AdminSettingsController.php
@@ -135,6 +135,10 @@ class AdminSettingsController extends Controller {
/** @var \OC\Settings\Section[] $prioritizedSections */
foreach($sections as $prioritizedSections) {
foreach ($prioritizedSections as $section) {
+ if (empty($this->settingsManager->getAdminSettings($section->getID()))) {
+ continue;
+ }
+
$icon = '';
if ($section instanceof IIconSection) {
$icon = $section->getIcon();