Permissions: Validate against Team/User permission role update (#29101)
* validate against role field update * lowercase error string * make all msgs consistent style * fix wording Co-authored-by: Arve Knudsen <arve.knudsen@gmail.com> * sayonara simple json Co-authored-by: Arve Knudsen <arve.knudsen@gmail.com>
This commit is contained in:
co-authored by
Arve Knudsen
parent
0cfb967404
commit
2939caf9a2
@@ -49,6 +49,10 @@ func GetFolderPermissionList(c *models.ReqContext) Response {
|
||||
}
|
||||
|
||||
func UpdateFolderPermissions(c *models.ReqContext, apiCmd dtos.UpdateDashboardAclCommand) Response {
|
||||
if err := validatePermissionsUpdate(apiCmd); err != nil {
|
||||
return Error(400, err.Error(), err)
|
||||
}
|
||||
|
||||
s := dashboards.NewFolderService(c.OrgId, c.SignedInUser)
|
||||
folder, err := s.GetFolderByUID(c.Params(":uid"))
|
||||
|
||||
|
||||
Reference in New Issue
Block a user