fmt
This commit is contained in:
parent
358b569bf1
commit
6ea4f0598c
1 changed files with 1 additions and 1 deletions
|
@ -49,7 +49,7 @@ func UserChangePassword(c echo.Context) error {
|
||||||
}
|
}
|
||||||
|
|
||||||
// Check the current password
|
// Check the current password
|
||||||
if _, err = models.CheckUserCredentials(&models.UserLogin{Username:doer.Username,Password:newPW.OldPassword}); err != nil {
|
if _, err = models.CheckUserCredentials(&models.UserLogin{Username: doer.Username, Password: newPW.OldPassword}); err != nil {
|
||||||
if models.IsErrUserDoesNotExist(err) {
|
if models.IsErrUserDoesNotExist(err) {
|
||||||
return echo.NewHTTPError(http.StatusNotFound, "The user does not exist.")
|
return echo.NewHTTPError(http.StatusNotFound, "The user does not exist.")
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue