From 250467e842a0856a84e9962ed6ef476a2e3ccfef Mon Sep 17 00:00:00 2001 From: Joas Schilling Date: Tue, 14 Apr 2020 17:53:15 +0200 Subject: Extend tests for root url Signed-off-by: Joas Schilling --- lib/private/AppFramework/Routing/RouteConfig.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'lib') diff --git a/lib/private/AppFramework/Routing/RouteConfig.php b/lib/private/AppFramework/Routing/RouteConfig.php index af745a35fcc..2f2d51f6e1a 100644 --- a/lib/private/AppFramework/Routing/RouteConfig.php +++ b/lib/private/AppFramework/Routing/RouteConfig.php @@ -55,7 +55,7 @@ class RouteConfig { /** @var string[] */ private $controllerNameCache = []; - public const ROOT_URL_APPS = [ + protected $rootUrlApps = [ 'cloud_federation_api', 'core', 'files_sharing', @@ -126,7 +126,7 @@ class RouteConfig { $postfix = $route['postfix'] ?? ''; $defaultRoot = $this->appName === 'core' ? '' : '/apps/' . $this->appName; $root = $route['root'] ?? $defaultRoot; - if ($routeNamePrefix === '' && !\in_array($this->appName, self::ROOT_URL_APPS, true)) { + if ($routeNamePrefix === '' && !\in_array($this->appName, $this->rootUrlApps, true)) { // Only allow root URLS for some apps $root = $defaultRoot; } -- cgit v1.2.3