Cookie with 0 minutes == no expires attribute
This commit is contained in:
parent
dc737a397d
commit
0859d92efc
@ -748,7 +748,10 @@ headerToPair cp getExpires (AddCookie minutes key value) =
|
|||||||
{ setCookieName = key
|
{ setCookieName = key
|
||||||
, setCookieValue = value
|
, setCookieValue = value
|
||||||
, setCookiePath = Just cp
|
, setCookiePath = Just cp
|
||||||
, setCookieExpires = Just $ getExpires minutes
|
, setCookieExpires =
|
||||||
|
if minutes == 0
|
||||||
|
then Nothing
|
||||||
|
else Just $ getExpires minutes
|
||||||
, setCookieDomain = Nothing
|
, setCookieDomain = Nothing
|
||||||
})
|
})
|
||||||
headerToPair cp _ (DeleteCookie key) =
|
headerToPair cp _ (DeleteCookie key) =
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user