Get returns a session for the given name after adding it to the registry. It returns a new session if the sessions doesn't exist. Access IsNew on the session to check if it is an existing session or a new one. It returns a new session and an error if the session exists but could not be decoded.
(r *http.Request, name string)
| 79 | // It returns a new session and an error if the session exists but could |
| 80 | // not be decoded. |
| 81 | func (s *CookieStore) Get(r *http.Request, name string) (*Session, error) { |
| 82 | return GetRegistry(r).Get(s, name) |
| 83 | } |
| 84 | |
| 85 | // New returns a session for the given name without adding it to the registry. |
| 86 | // |