mirror of
https://github.com/gravitl/netmaker.git
synced 2025-11-03 11:02:11 +08:00
force set default acl field to false
This commit is contained in:
@@ -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"))
|
||||
|
||||
Reference in New Issue
Block a user