-
Notifications
You must be signed in to change notification settings - Fork 637
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
bug(http): missing docs and setCookie()
allows Max-age
to be 0
#4426
Comments
|
setCookie()
allows Max-age
to be 0
ping to @asos-craigmorten @SimonRask @wperron So this would be basically a regression? I think we should allow negative numbers. |
While adding this isn't a big deal, |
I think the fix #4459 needs more support from the community to be landed. |
who can make the decision? tbh. I still think that we should allow negativ integers. |
@Uzlopak, can you please explain why you can't just use |
I personally think the current state is a good compromise between what RFC encourage to do (max-age > 0) and what people believe to work (max-age >= 0). I think the reason why people think |
Closing this now. Let's keep the current behavior. @Uzlopak, please feel free to re-open if you're able to provide reasoning behind wanting to support negative expiries. Either way, thank you for the suggestion. |
Description
Regarding this line: https://github.com/denoland/deno_std/blob/45f7a6b46018e9f4d330943918299c68ae80f1bb/http/cookie.ts#L91
While working on the cookie implementation in undici/node, I realized that the max-age implementation is slightly off.
This is what I wrote to the corresponding code piece in the undici PR
nodejs/undici#2888
Expected behavior
Negative numbers should be allowed
The text was updated successfully, but these errors were encountered: