mirror of
https://github.com/awatertrevi/infisical.git
synced 2026-10-07 00:27:30 +00:00
Fix lint issue
This commit is contained in:
+4
@@ -64,6 +64,10 @@ const schema = yup.object({
|
|||||||
accessTokenTTL: yup
|
accessTokenTTL: yup
|
||||||
.string()
|
.string()
|
||||||
.test("is-positive-integer", "Access Token TTL must be a positive integer", (value) => {
|
.test("is-positive-integer", "Access Token TTL must be a positive integer", (value) => {
|
||||||
|
if (typeof value === "undefined") {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
const num = parseInt(value, 10);
|
const num = parseInt(value, 10);
|
||||||
return !Number.isNaN(num) && num > 0 && String(num) === value;
|
return !Number.isNaN(num) && num > 0 && String(num) === value;
|
||||||
})
|
})
|
||||||
|
|||||||
Reference in New Issue
Block a user