From a57017e80b74baf248fe9a217f1b0f9d7e68d5bc Mon Sep 17 00:00:00 2001 From: Simon Vieille Date: Tue, 13 Oct 2020 11:09:14 +0200 Subject: [PATCH] fix issue with personal settings when global settings are forced --- lib/Controller/NavController.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/Controller/NavController.php b/lib/Controller/NavController.php index b79aad4..127eb85 100644 --- a/lib/Controller/NavController.php +++ b/lib/Controller/NavController.php @@ -98,6 +98,7 @@ class NavController extends Controller $currentLanguage = substr($this->l10nFactory->findLanguage(), 0, 2); $externalSitesInTopMenu = $this->config->getAppValueBool('external-sites-in-top-menu', '0'); $user = OC::$server[IUserSession::class]->getUser(); + $isForced = $this->config->getAppValueBool('force', '0'); $appsCategories = []; $categoriesAppsCount = []; $items = []; @@ -119,7 +120,7 @@ class NavController extends Controller $topMenuApps = $this->config->getAppValueArray('top-menu-apps', '[]'); $userTopMenuApps = $this->config->getUserValueArray($user, 'top-menu-apps', '[]'); - if (!empty($userTopMenuApps)) { + if (!$isForced && !empty($userTopMenuApps)) { $topMenuApps = $userTopMenuApps; }