Chore: Remove star model duplicates (#61191)

This commit is contained in:
Kat Yang
2023-01-10 09:56:33 -05:00
committed by GitHub
parent 320266ae63
commit 9a14a7db03
4 changed files with 6 additions and 45 deletions
+2 -1
View File
@@ -22,6 +22,7 @@ import (
"github.com/grafana/grafana/pkg/services/sqlstore/migrator"
"github.com/grafana/grafana/pkg/services/sqlstore/permissions"
"github.com/grafana/grafana/pkg/services/sqlstore/searchstore"
"github.com/grafana/grafana/pkg/services/star"
"github.com/grafana/grafana/pkg/services/store"
"github.com/grafana/grafana/pkg/services/tag"
"github.com/grafana/grafana/pkg/setting"
@@ -963,7 +964,7 @@ func (d *DashboardStore) GetDashboardUIDById(ctx context.Context, query *models.
func (d *DashboardStore) GetDashboards(ctx context.Context, query *models.GetDashboardsQuery) error {
return d.store.WithDbSession(ctx, func(sess *db.Session) error {
if len(query.DashboardIds) == 0 && len(query.DashboardUIds) == 0 {
return models.ErrCommandValidationFailed
return star.ErrCommandValidationFailed
}
var dashboards = make([]*models.Dashboard, 0)