Mercurial > gemma
diff pkg/controllers/token.go @ 493:8a0737aa6ab6 metamorph-for-all
The connection pool is now only a session store.
author | Sascha L. Teichmann <sascha.teichmann@intevation.de> |
---|---|
date | Fri, 24 Aug 2018 14:25:05 +0200 |
parents | 2ac37419f593 |
children | 7474e9922ed5 |
line wrap: on
line diff
--- a/pkg/controllers/token.go Fri Aug 24 13:56:06 2018 +0200 +++ b/pkg/controllers/token.go Fri Aug 24 14:25:05 2018 +0200 @@ -19,7 +19,7 @@ func renew(rw http.ResponseWriter, req *http.Request) { token, _ := auth.GetToken(req) - newToken, err := auth.ConnPool.Renew(token) + newToken, err := auth.Sessions.Renew(token) switch { case err == auth.ErrNoSuchToken: http.NotFound(rw, req) @@ -48,7 +48,7 @@ func logout(rw http.ResponseWriter, req *http.Request) { token, ok := auth.GetToken(req) - if !ok || !auth.ConnPool.Delete(token) { + if !ok || !auth.Sessions.Delete(token) { http.NotFound(rw, req) return }