Merge pull request #1158 from taigaio/issue/4756/dont-change-email-without-validation

Remove change-email-validation from the history of the browser
stable
Alejandro 2016-11-15 13:40:18 +01:00 committed by GitHub
commit 5d09ba4629
1 changed files with 2 additions and 0 deletions

View File

@ -574,8 +574,10 @@ ChangeEmailDirective = ($repo, $model, $auth, $confirm, $location, $params, $nav
$repo.queryOne("users", $auth.getUser().id).then (data) =>
$auth.setUser(data)
$location.path($navUrls.resolve("home"))
$location.replace()
else
$location.path($navUrls.resolve("login"))
$location.replace()
text = $translate.instant("CHANGE_EMAIL_FORM.SUCCESS")
$confirm.success(text)