mirror of
https://github.com/gravitl/netmaker.git
synced 2025-09-09 22:55:02 +08:00
force set default acl field to false
This commit is contained in:
parent
dfed77906a
commit
4e825f7b9e
1 changed files with 1 additions and 0 deletions
|
@ -85,6 +85,7 @@ func createAcl(w http.ResponseWriter, r *http.Request) {
|
|||
acl.ID = uuid.New()
|
||||
acl.CreatedBy = user.UserName
|
||||
acl.CreatedAt = time.Now().UTC()
|
||||
acl.Default = false
|
||||
// validate create acl policy
|
||||
if !logic.IsAclPolicyValid(acl) {
|
||||
logic.ReturnErrorResponse(w, r, logic.FormatError(errors.New("invalid policy"), "badrequest"))
|
||||
|
|
Loading…
Add table
Reference in a new issue