1
0
mirror of https://github.com/kataras/iris.git synced 2025-12-24 05:17:03 +00:00

comment fix as reported at #1574

This commit is contained in:
Gerasimos (Makis) Maropoulos
2020-08-09 05:46:02 +03:00
parent 46a3a99adf
commit 5de9d0f63e
3 changed files with 8 additions and 8 deletions

View File

@@ -4216,14 +4216,14 @@ func (ctx *Context) UpsertCookie(cookie *http.Cookie, options ...CookieOption) b
// SetCookieKVExpiration is 365 days by-default
// you can change it or simple, use the SetCookie for more control.
//
// See CookieExpires` for more.
// See `CookieExpires` and `AddCookieOptions` for more.
var SetCookieKVExpiration = time.Duration(8760) * time.Hour
// SetCookieKV adds a cookie, requires the name(string) and the value(string).
//
// By default it expires at 2 hours and it's added to the root path,
// By default it expires after 365 days and it is added to the root URL path,
// use the `CookieExpires` and `CookiePath` to modify them.
// Alternatively: ctx.SetCookie(&http.Cookie{...})
// Alternatively: ctx.SetCookie(&http.Cookie{...}) or ctx.AddCookieOptions(...)
//
// If you want to set custom the path:
// ctx.SetCookieKV(name, value, iris.CookiePath("/custom/path/cookie/will/be/stored"))