mirror of
https://github.com/kyverno/kyverno.git
synced 2024-12-14 11:57:48 +00:00
fix: check subjects func (#8470)
Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com>
This commit is contained in:
parent
b692e3b817
commit
f38011cd8e
1 changed files with 1 additions and 4 deletions
|
@ -7,10 +7,7 @@ import (
|
|||
)
|
||||
|
||||
// CheckSubjects return true if one of ruleSubjects exist in userInfo
|
||||
func CheckSubjects(
|
||||
ruleSubjects []rbacv1.Subject,
|
||||
userInfo authenticationv1.UserInfo,
|
||||
) bool {
|
||||
func CheckSubjects(ruleSubjects []rbacv1.Subject, userInfo authenticationv1.UserInfo) bool {
|
||||
for _, subject := range ruleSubjects {
|
||||
switch subject.Kind {
|
||||
case rbacv1.ServiceAccountKind:
|
||||
|
|
Loading…
Reference in a new issue