do not actually write the value

This commit is contained in:
Ryan McKinley
2025-12-18 10:47:07 +03:00
parent b605f464a4
commit 71fda4fa42
+1 -2
View File
@@ -21,7 +21,6 @@ import (
common "github.com/grafana/grafana/pkg/apimachinery/apis/common/v0alpha1"
"github.com/grafana/grafana/pkg/apimachinery/utils"
secrets "github.com/grafana/grafana/pkg/registry/apis/secret/contracts"
"github.com/grafana/grafana/pkg/services/folder"
"github.com/grafana/grafana/pkg/storage/unified/resourcepb"
)
@@ -82,7 +81,7 @@ func (s *Storage) verifyFolder(obj utils.GrafanaMetaAccessor) error {
if obj.GetFolder() == "" {
// return apierrors.NewBadRequest("missing folder annotation")
// TODO?: should this be optionally be done in a mutation webhook?
obj.SetFolder(folder.GeneralFolderUID) // always enter something
// ???? obj.SetFolder(folder.GeneralFolderUID) // always enter something
return nil
}
} else if obj.GetFolder() != "" {