Folder UID scope resolver (#46426)

This commit is contained in:
Yuriy Tseretyan
2022-03-15 15:37:16 +01:00
committed by GitHub
parent f46038ed3a
commit e62e9904ee
4 changed files with 78 additions and 1 deletions
@@ -34,6 +34,7 @@ func ProvideFolderService(
ac accesscontrol.AccessControl,
) *FolderServiceImpl {
ac.RegisterAttributeScopeResolver(dashboards.NewNameScopeResolver(dashboardStore))
ac.RegisterAttributeScopeResolver(dashboards.NewUidScopeResolver(dashboardStore))
return &FolderServiceImpl{
cfg: cfg,
@@ -40,7 +40,7 @@ func TestProvideFolderService(t *testing.T) {
store, nil, features, permissionsServices, ac,
)
require.Len(t, ac.Calls.RegisterAttributeScopeResolver, 1)
require.Len(t, ac.Calls.RegisterAttributeScopeResolver, 2)
})
}