Chore: Deprecate FolderID from Dashboard (#77823)

* Chore: Deprecate FolderID from Dashboard

* chore: add two missing nolint comments
This commit is contained in:
Kat Yang
2023-11-15 10:28:50 -05:00
committed by GitHub
parent 0214b25663
commit 3a2e96b0db
28 changed files with 92 additions and 27 deletions
@@ -777,7 +777,7 @@ func setupTest(t *testing.T, numFolders, numDashboards int, permissions []access
dashes = append(dashes, dashboards.Dashboard{
OrgID: 1,
IsFolder: false,
FolderID: int64(folderID),
FolderID: int64(folderID), // nolint:staticcheck
UID: str,
Slug: str,
Title: str,
@@ -132,7 +132,7 @@ func setupBenchMark(b *testing.B, usr user.SignedInUser, features featuremgmt.Fe
Data: simplejson.New(),
Created: now,
Updated: now,
FolderID: leaf.ID,
FolderID: leaf.ID, // nolint:staticcheck
})
}
@@ -176,6 +176,7 @@ func setupBenchMark(b *testing.B, usr user.SignedInUser, features featuremgmt.Fe
})
for _, dash := range dashes {
// add permission to read dashboards under the general
// nolint:staticcheck
if dash.FolderID == 0 {
permissions = append(permissions, accesscontrol.Permission{
RoleID: int64(i),