parent
16f16e8a15
commit
31a8a0fba4
7 changed files with 76 additions and 11 deletions
|
@ -24,15 +24,15 @@ angular.module('quay').directive('userSetup', function () {
|
|||
$scope.sendRecovery = function() {
|
||||
$scope.sendingRecovery = true;
|
||||
|
||||
ApiService.requestRecoveryEmail($scope.recovery).then(function() {
|
||||
ApiService.requestRecoveryEmail($scope.recovery).then(function(resp) {
|
||||
$scope.invalidRecovery = false;
|
||||
$scope.errorMessage = '';
|
||||
$scope.sent = true;
|
||||
$scope.sent = resp;
|
||||
$scope.sendingRecovery = false;
|
||||
}, function(resp) {
|
||||
$scope.invalidRecovery = true;
|
||||
$scope.errorMessage = ApiService.getErrorMessage(resp, 'Cannot send recovery email');
|
||||
$scope.sent = false;
|
||||
$scope.sent = null;
|
||||
$scope.sendingRecovery = false;
|
||||
});
|
||||
};
|
||||
|
|
Reference in a new issue