mirror of
https://github.com/zigzap/zap.git
synced 2025-10-20 23:24:09 +00:00
Merge pull request #19 from edyu/master
cookie Max-Age should be set to -1 when invalidating the cookie
This commit is contained in:
commit
8aec624462
1 changed files with 2 additions and 2 deletions
|
@ -408,7 +408,7 @@ pub fn UserPassSessionAuth(comptime Lookup: type, comptime lockedPwLookups: bool
|
|||
if (r.setCookie(.{
|
||||
.name = self.settings.cookieName,
|
||||
.value = "invalid",
|
||||
.max_age_s = self.settings.cookieMaxAge,
|
||||
.max_age_s = -1,
|
||||
})) {
|
||||
zap.debug("logout ok\n", .{});
|
||||
} else |err| {
|
||||
|
@ -424,7 +424,7 @@ pub fn UserPassSessionAuth(comptime Lookup: type, comptime lockedPwLookups: bool
|
|||
if (r.setCookie(.{
|
||||
.name = self.settings.cookieName,
|
||||
.value = "invalid",
|
||||
.max_age_s = self.settings.cookieMaxAge,
|
||||
.max_age_s = -1,
|
||||
})) {
|
||||
zap.debug("logout ok\n", .{});
|
||||
} else |err| {
|
||||
|
|
Loading…
Add table
Reference in a new issue