Skip to content

Commit

Permalink
chore: synchronize workspaces
Browse files Browse the repository at this point in the history
  • Loading branch information
aeneasr committed Oct 31, 2024
1 parent 65ed134 commit 12fa25b
Showing 1 changed file with 0 additions and 4 deletions.
4 changes: 0 additions & 4 deletions jwk/helper.go
Original file line number Diff line number Diff line change
Expand Up @@ -45,10 +45,6 @@ func EnsureAsymmetricKeypairExists(ctx context.Context, r InternalRegistry, alg,

func GetOrGenerateKeys(ctx context.Context, r InternalRegistry, m Manager, set, kid, alg string) (private *jose.JSONWebKey, err error) {
keys, err := m.GetKeySet(ctx, set)
if err == nil && keys != nil && len(keys.Keys) > 0 {
return FindPrivateKey(keys)
}

if errors.Is(err, x.ErrNotFound) || keys != nil && len(keys.Keys) == 0 {
r.Logger().Warnf("JSON Web Key Set \"%s\" does not exist yet, generating new key pair...", set)
getLock(set).Lock()
Expand Down

0 comments on commit 12fa25b

Please sign in to comment.