Skip to content

Commit

Permalink
Merge 7f087a4 into 7a405ab
Browse files Browse the repository at this point in the history
  • Loading branch information
calebdoxsey committed Feb 2, 2023
2 parents 7a405ab + 7f087a4 commit cdede64
Showing 1 changed file with 7 additions and 5 deletions.
12 changes: 7 additions & 5 deletions databroker/cache.go
Expand Up @@ -164,11 +164,13 @@ func (c *DataBroker) update(ctx context.Context, cfg *config.Config) error {
manager.WithEventManager(c.eventsMgr),
}

authenticator, err := identity.NewAuthenticator(oauthOptions)
if err != nil {
log.Error(ctx).Err(err).Msg("databroker: failed to create authenticator")
} else {
options = append(options, manager.WithAuthenticator(authenticator))
if cfg.Options.Provider != "" {
authenticator, err := identity.NewAuthenticator(oauthOptions)
if err != nil {
log.Error(ctx).Err(err).Msg("databroker: failed to create authenticator")
} else {
options = append(options, manager.WithAuthenticator(authenticator))
}
}

if c.manager == nil {
Expand Down

0 comments on commit cdede64

Please sign in to comment.