mirror of
https://github.com/go-acme/lego.git
synced 2025-01-20 13:15:32 +02:00
errors.New -> fmt.Errorf
This commit is contained in:
parent
3ab9b75696
commit
e81192c912
@ -10,7 +10,6 @@ import (
|
||||
"net/http"
|
||||
|
||||
"gopkg.in/square/go-jose.v1"
|
||||
"errors"
|
||||
)
|
||||
|
||||
type jws struct {
|
||||
@ -103,7 +102,7 @@ func (j *jws) Nonce() (string, error) {
|
||||
}
|
||||
}
|
||||
if len(j.nonces) == 0 {
|
||||
return "", errors.New("Can't get nonce")
|
||||
return "", fmt.Errorf("Can't get nonce")
|
||||
}
|
||||
nonce, j.nonces = j.nonces[len(j.nonces)-1], j.nonces[:len(j.nonces)-1]
|
||||
return nonce, nil
|
||||
|
Loading…
x
Reference in New Issue
Block a user