mirror of
https://github.com/mattermost/mattermost.git
synced 2025-02-25 18:55:24 -06:00
Remove temporary cookie code (#7218)
This commit is contained in:
committed by
Christopher Speller
parent
339b30e1da
commit
e40fd0b3b5
@@ -182,20 +182,6 @@ func (h handler) ServeHTTP(w http.ResponseWriter, r *http.Request) {
|
||||
}
|
||||
}
|
||||
|
||||
// TEMPORARY CODE FOR 3.9, REMOVE FOR 3.10
|
||||
if cookie, err := r.Cookie(model.SESSION_COOKIE_TOKEN); err == nil && c.Session.UserId != "" {
|
||||
if _, err = r.Cookie(model.SESSION_COOKIE_USER); err != nil {
|
||||
http.SetCookie(w, &http.Cookie{
|
||||
Name: model.SESSION_COOKIE_USER,
|
||||
Value: c.Session.UserId,
|
||||
Path: "/",
|
||||
MaxAge: cookie.MaxAge,
|
||||
Expires: cookie.Expires,
|
||||
Secure: cookie.Secure,
|
||||
})
|
||||
}
|
||||
}
|
||||
|
||||
if h.isApi || h.isTeamIndependent {
|
||||
c.setTeamURL(c.GetSiteURLHeader(), false)
|
||||
c.Path = r.URL.Path
|
||||
|
||||
Reference in New Issue
Block a user