From 284c2d6f7184e921a522a0af027500e67b6f9b0d Mon Sep 17 00:00:00 2001 From: Ieva Date: Tue, 15 Oct 2024 10:45:07 +0100 Subject: [PATCH] Folders: Correctly show new folder button under root folder (#94687) show new folder button under root folder if nested folders are disabled and user has the right perms --- public/app/features/browse-dashboards/permissions.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/public/app/features/browse-dashboards/permissions.ts b/public/app/features/browse-dashboards/permissions.ts index d4043434bce..3347fb9f442 100644 --- a/public/app/features/browse-dashboards/permissions.ts +++ b/public/app/features/browse-dashboards/permissions.ts @@ -8,7 +8,7 @@ function checkFolderPermission(action: AccessControlAction, folderDTO?: FolderDT function checkCanCreateFolders(folderDTO?: FolderDTO) { // Can only create a folder if we have permissions and either we're at root or nestedFolders is enabled - if (folderDTO && !config.featureToggles.nestedFolders) { + if (folderDTO && folderDTO.uid !== 'general' && !config.featureToggles.nestedFolders) { return false; }