Skip to content

Commit

Permalink
Fix: call SetProjects only if needed
Browse files Browse the repository at this point in the history
  • Loading branch information
Wilfried OLLIVIER committed Sep 23, 2020
1 parent ecb8396 commit 8400d84
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion pkg/validation/options.go
Original file line number Diff line number Diff line change
Expand Up @@ -292,7 +292,9 @@ func parseProviderInfo(o *options.Options, msgs []string) []string {
case *providers.GitLabProvider:
p.AllowUnverifiedEmail = o.InsecureOIDCAllowUnverifiedEmail
p.Groups = o.GitLabGroup
p.SetProjects(o.GitlabProjects)
if len(o.GitlabProjects) > 0 {
p.SetProjects(o.GitlabProjects)
}
p.EmailDomains = o.EmailDomains

if o.GetOIDCVerifier() != nil {
Expand Down

0 comments on commit 8400d84

Please sign in to comment.