mirror of https://github.com/golang-jwt/jwt.git
Refactor by removing unnecessary []byte conversion to string (#330)
This commit is contained in:
parent
8b7470d561
commit
fc86f52277
2
none.go
2
none.go
|
@ -32,7 +32,7 @@ func (m *signingMethodNone) Verify(signingString string, sig []byte, key interfa
|
|||
return NoneSignatureTypeDisallowedError
|
||||
}
|
||||
// If signing method is none, signature must be an empty string
|
||||
if string(sig) != "" {
|
||||
if len(sig) != 0 {
|
||||
return newError("'none' signing method with non-empty signature", ErrTokenUnverifiable)
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue