internal: fix typo in session name constant

Signed-off-by: Jens Langhammer <jens.langhammer@beryju.org>
This commit is contained in:
Jens Langhammer
2022-05-20 10:10:26 +02:00
parent 5bc893b890
commit a52638d898
9 changed files with 22 additions and 22 deletions

View File

@ -22,7 +22,7 @@ func urlJoin(originalUrl string, newPath string) string {
}
func (a *Application) redirectToStart(rw http.ResponseWriter, r *http.Request) {
s, err := a.sessions.Get(r, constants.SeesionName)
s, err := a.sessions.Get(r, constants.SessionName)
if err != nil {
a.log.WithError(err).Warning("failed to decode session")
}
@ -52,7 +52,7 @@ func (a *Application) redirectToStart(rw http.ResponseWriter, r *http.Request) {
// getClaims Get claims which are currently in session
// Returns an error if the session can't be loaded or the claims can't be parsed/type-cast
func (a *Application) getClaims(r *http.Request) (*Claims, error) {
s, err := a.sessions.Get(r, constants.SeesionName)
s, err := a.sessions.Get(r, constants.SessionName)
if err != nil {
// err == user has no session/session is not valid, reject
return nil, fmt.Errorf("invalid session")