security/api-keys: clarify error when number is not positive
This commit is contained in:
parent
81818f8741
commit
3d7713a942
1 changed files with 1 additions and 1 deletions
|
@ -51,7 +51,7 @@ const validateKeys = (input) => {
|
||||||
if (typeof details.limit !== 'number')
|
if (typeof details.limit !== 'number')
|
||||||
throw "detail object contains invalid limit (not a number)";
|
throw "detail object contains invalid limit (not a number)";
|
||||||
else if (details.limit < 1)
|
else if (details.limit < 1)
|
||||||
throw "detail object contains invalid limit (not a number)";
|
throw "detail object contains invalid limit (not a positive number)";
|
||||||
}
|
}
|
||||||
|
|
||||||
if (details.ips) {
|
if (details.ips) {
|
||||||
|
|
Loading…
Reference in a new issue