Login: only enabled oauth options are shown on login page

This commit is contained in:
Torkel Ödegaard committed 2015-01-28 10:26:13 +01:00
1 parent a5e450a0dd
commit aa261bbe23
2 files changed
+5 -1

No files matched your search

+1 -1
Submodule grafana updated: 4572747bd6...017eab8dcd.
+4
View File
@@ -22,6 +22,10 @@ func LoginView(c *middleware.Context) {
return
}
settings := c.Data["Settings"].(map[string]interface{})
settings["googleAuthEnabled"] = setting.OAuthService.Google
settings["githubAuthEnabled"] = setting.OAuthService.GitHub
// Check auto-login.
uname := c.GetCookie(setting.CookieUserName)
if len(uname) == 0 {