aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLoïc Hoguin <[email protected]>2022-10-24 16:40:23 +0200
committerLoïc Hoguin <[email protected]>2022-10-24 16:40:23 +0200
commit7507a8abbca2b7fe14ad18336d807581f6ce4f59 (patch)
treef0960358b43df73881ec3062b7c05d8050fb2143
parent2c6f1449d6e9eeae9a67364a53d11ca23f628854 (diff)
downloadgun-7507a8abbca2b7fe14ad18336d807581f6ce4f59.tar.gz
gun-7507a8abbca2b7fe14ad18336d807581f6ce4f59.tar.bz2
gun-7507a8abbca2b7fe14ad18336d807581f6ce4f59.zip
Cookies: default SameSite is now "Default", not "None"
-rw-r--r--src/gun_cookies.erl4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/gun_cookies.erl b/src/gun_cookies.erl
index 984e491..b07f4b5 100644
--- a/src/gun_cookies.erl
+++ b/src/gun_cookies.erl
@@ -44,7 +44,7 @@
host_only := boolean(),
secure_only := boolean(),
http_only := boolean(),
- same_site := strict | lax | none
+ same_site := default | none | strict | lax
}.
-export_type([cookie/0]).
@@ -286,7 +286,7 @@ set_cookie_secure_match({Mod, State}, Match) ->
Mod:set_cookie_secure_match(State, Match).
set_cookie2(Store, _URI, Attrs, Cookie0) ->
- Cookie = Cookie0#{same_site => maps:get(same_site, Attrs, none)},
+ Cookie = Cookie0#{same_site => maps:get(same_site, Attrs, default)},
%% This is where we would perform the same-site checks.
%%
%% It seems that an option would need to be added to Gun