From a74ebaa1eb7a819adb3823580dc56035f300e4f9 Mon Sep 17 00:00:00 2001 From: Miroslav Genov Date: Sun, 13 Nov 2016 10:01:29 +0200 Subject: [PATCH] beego/session: return proper error when session is not found Parent errs was returned instead of err which is returned from the last statement. --- session/session.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/session/session.go b/session/session.go index 9df468ba..fb4b2821 100644 --- a/session/session.go +++ b/session/session.go @@ -207,7 +207,7 @@ func (manager *Manager) SessionStart(w http.ResponseWriter, r *http.Request) (se session, err = manager.provider.SessionRead(sid) if err != nil { - return nil, errs + return nil, err } cookie := &http.Cookie{ Name: manager.config.CookieName,