correct cookie docs (#19122)
This commit is contained in:
parent
036d894e6a
commit
7313b70a6a
1 changed files with 1 additions and 2 deletions
|
|
@ -51,8 +51,7 @@ proc setCookie*(key, value: string, domain = "", path = "",
|
||||||
## Creates a command in the format of
|
## Creates a command in the format of
|
||||||
## `Set-Cookie: key=value; Domain=...; ...`
|
## `Set-Cookie: key=value; Domain=...; ...`
|
||||||
##
|
##
|
||||||
|
## .. tip:: Cookies can be vulnerable. Consider setting `secure=true`, `httpOnly=true` and `sameSite=Strict`.
|
||||||
## .. tip: Cookies can be vulnerable. Consider setting `secure=true`, `httpOnly=true` and `sameSite=Strict`.
|
|
||||||
result = ""
|
result = ""
|
||||||
if not noName: result.add("Set-Cookie: ")
|
if not noName: result.add("Set-Cookie: ")
|
||||||
result.add key & "=" & value
|
result.add key & "=" & value
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue