mirror of
https://github.com/mattermost/mattermost.git
synced 2025-02-25 18:55:24 -06:00
Fixes mm-1415 adding email bypass flag
This commit is contained in:
@@ -68,7 +68,7 @@ func signupTeam(c *Context, w http.ResponseWriter, r *http.Request) {
|
||||
return
|
||||
}
|
||||
|
||||
if utils.Cfg.ServiceSettings.Mode == utils.MODE_DEV {
|
||||
if utils.Cfg.ServiceSettings.Mode == utils.MODE_DEV || utils.Cfg.EmailSettings.ByPassEmail {
|
||||
m["follow_link"] = bodyPage.Props["Link"]
|
||||
}
|
||||
|
||||
|
||||
@@ -293,7 +293,7 @@ func login(c *Context, w http.ResponseWriter, r *http.Request) {
|
||||
return
|
||||
}
|
||||
|
||||
if !user.EmailVerified {
|
||||
if !user.EmailVerified && !utils.Cfg.EmailSettings.ByPassEmail {
|
||||
c.Err = model.NewAppError("login", "Login failed because email address has not been verified", extraInfo)
|
||||
c.Err.StatusCode = http.StatusForbidden
|
||||
return
|
||||
|
||||
Reference in New Issue
Block a user