Change error message
This commit is contained in:
2
index.js
2
index.js
@@ -87,7 +87,7 @@ class JWT {
|
||||
throw new Error('options.algorithm must be a string')
|
||||
const tokenParts = token.split('.')
|
||||
if (tokenParts.length !== 3)
|
||||
throw new Error('token must have 3 parts')
|
||||
throw new Error('token must consist of 3 parts')
|
||||
const importAlgorithm = this.algorithms[options.algorithm]
|
||||
if (!importAlgorithm)
|
||||
throw new Error('algorithm not found')
|
||||
|
||||
Reference in New Issue
Block a user