Skip to content

Commit

Permalink
optmize
Browse files Browse the repository at this point in the history
  • Loading branch information
wxiaoguang committed Feb 17, 2024
1 parent 507ec03 commit ef40ef3
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion modules/setting/oauth2.go
Original file line number Diff line number Diff line change
Expand Up @@ -167,7 +167,9 @@ func GetGeneralTokenSigningSecret() []byte {
}
if generalSigningSecret.CompareAndSwap(old, &jwtSecret) {
log.Warn("OAuth2 is not enabled, unable to use a persistent signing secret, a new one is generated, which is not persistent between restarts and cluster nodes")
return jwtSecret
}
return *generalSigningSecret.Load()
}
return *generalSigningSecret.Load()
return *old
}

0 comments on commit ef40ef3

Please sign in to comment.