Skip to content

Commit

Permalink
fix linter and simplify anyNamespaceAllows
Browse files Browse the repository at this point in the history
  • Loading branch information
lgfa29 committed Jul 6, 2022
1 parent de40f4d commit 00ec288
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions acl/acl.go
Original file line number Diff line number Diff line change
Expand Up @@ -363,11 +363,7 @@ func (a *ACL) anyNamespaceAllows(cb func(capabilitySet) bool) bool {

checkFn := func(_ []byte, iv interface{}) bool {
v := iv.(capabilitySet)
allow = cb(v)
if allow {
return true
}
return false
return cb(v)
}

a.namespaces.Root().Walk(checkFn)
Expand Down

0 comments on commit 00ec288

Please sign in to comment.