mirror of
https://github.com/astaxie/beego.git
synced 2024-11-22 06:50:54 +00:00
update session fix
This commit is contained in:
parent
6d96345499
commit
bf144d5835
@ -71,6 +71,8 @@ func (manager *Manager) SessionStart(w http.ResponseWriter, r *http.Request) (se
|
||||
r.AddCookie(&cookie)
|
||||
} else {
|
||||
cookie.Expires = time.Now().Add(time.Duration(manager.maxlifetime) * time.Second)
|
||||
cookie.HttpOnly = true
|
||||
cookie.Path = "/"
|
||||
http.SetCookie(w, cookie)
|
||||
sid, _ := url.QueryUnescape(cookie.Value)
|
||||
session, _ = manager.provider.SessionRead(sid)
|
||||
|
Loading…
Reference in New Issue
Block a user