diff options
author | Harrison Healey <harrisonmhealey@gmail.com> | 2018-09-10 07:42:59 -0400 |
---|---|---|
committer | Martin Kraft <martinkraft@gmail.com> | 2018-09-10 07:42:59 -0400 |
commit | 435ce3df4b1671643f5427b8983d6a0fe1e1dc03 (patch) | |
tree | 25e8d86b934a04b0751e63500de931c55f3875aa | |
parent | 504591e7d69ba37aed48393c467d32a998a76751 (diff) | |
download | chat-435ce3df4b1671643f5427b8983d6a0fe1e1dc03.tar.gz chat-435ce3df4b1671643f5427b8983d6a0fe1e1dc03.tar.bz2 chat-435ce3df4b1671643f5427b8983d6a0fe1e1dc03.zip |
Stop re-wrapping password reset email error in another error (#9382)
-rw-r--r-- | app/user.go | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/app/user.go b/app/user.go index fa4f36ff1..c8df2ca26 100644 --- a/app/user.go +++ b/app/user.go @@ -1176,11 +1176,7 @@ func (a *App) SendPasswordReset(email string, siteURL string) (bool, *model.AppE return false, err } - if _, err := a.SendPasswordResetEmail(user.Email, token, user.Locale, siteURL); err != nil { - return false, model.NewAppError("SendPasswordReset", "api.user.send_password_reset.send.app_error", nil, "err="+err.Message, http.StatusInternalServerError) - } - - return true, nil + return a.SendPasswordResetEmail(user.Email, token, user.Locale, siteURL) } func (a *App) CreatePasswordRecoveryToken(userId string) (*model.Token, *model.AppError) { |