diff options
author | Tuomo Ala-Vannesluoma <tuomoav@gmail.com> | 2018-06-28 21:50:02 +0300 |
---|---|---|
committer | Tuomo Ala-Vannesluoma <tuomoav@gmail.com> | 2018-06-30 22:51:43 +0300 |
commit | a57640fd330cc854b0d48a3b685dd61bec9cf57d (patch) | |
tree | 77342b90e0ccb51ac13c2ea18ed5c07f4b7a8d3d /internal | |
parent | a0ba5ba1c3397987be7159c7952dfa38da219ab7 (diff) |
Fix not exposing project existence when group is found but project is not
Diffstat (limited to 'internal')
-rw-r--r-- | internal/auth/auth.go | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/internal/auth/auth.go b/internal/auth/auth.go index 483b471d..b4e693fb 100644 --- a/internal/auth/auth.go +++ b/internal/auth/auth.go @@ -208,6 +208,14 @@ func destroySession(session *sessions.Session, w http.ResponseWriter, r *http.Re http.Redirect(w, r, getRequestAddress(r), 302) } +// IsAuthSupported checks if pages is running with the authentication support +func (a *Auth) IsAuthSupported() bool { + if a == nil { + return false + } + return true +} + // CheckAuthenticationWithoutProject checks if user is authenticated and has a valid token func (a *Auth) CheckAuthenticationWithoutProject(w http.ResponseWriter, r *http.Request) bool { |