Response.clearCookie returns Error: TypeError: option expires is invalid
#11
Labels
bug
Something isn't working
Error: TypeError: option expires is invalid
#11
Version
1.0.0-alpha.9
What happened
https://fiddle.fastly.dev/fiddle/c053c616
Doing
res.clearCookie
in Expressly results inError: TypeError: option expires is invalid
instead of the cookie being cleared.A workaround is to change this line to
this.cookie(key, "", { ...options, expires: new Date("Thu, 01 Jan 1970 00:00:00 GMT" )});
The text was updated successfully, but these errors were encountered: