Check all places to break the loop when object found

This commit is contained in:
lixiaobing10051267
2016-07-23 13:49:04 +08:00
parent 0e8d515225
commit be8d081539
5 changed files with 5 additions and 0 deletions

View File

@@ -389,6 +389,7 @@ func rulesMatch(expectedRules, actualRules []rbac.PolicyRule) bool {
for _, actualRule := range actualRules {
if reflect.DeepEqual(expectedRule, actualRule) {
found = true
break
}
}