diff options
Diffstat (limited to 'std/http/cookie.ts')
-rw-r--r-- | std/http/cookie.ts | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/std/http/cookie.ts b/std/http/cookie.ts index 5e4f38a29..10c9bd689 100644 --- a/std/http/cookie.ts +++ b/std/http/cookie.ts @@ -45,7 +45,7 @@ function toString(cookie: Cookie): string { if (cookie.httpOnly) { out.push("HttpOnly"); } - if (Number.isInteger(cookie.maxAge)) { + if (typeof cookie.maxAge === "number" && Number.isInteger(cookie.maxAge)) { assert(cookie.maxAge > 0, "Max-Age must be an integer superior to 0"); out.push(`Max-Age=${cookie.maxAge}`); } |