mirror of
https://github.com/moparisthebest/mail
synced 2024-12-21 14:58:49 -05:00
Improve error message in public key verifier
This commit is contained in:
parent
1ffcaf5487
commit
9841a59a9e
@ -13,6 +13,7 @@ var PublicKeyVerifierCtrl = function($scope, $location, $q, $timeout, $interval,
|
|||||||
|
|
||||||
return $q(function(resolve) {
|
return $q(function(resolve) {
|
||||||
// updates the GUI
|
// updates the GUI
|
||||||
|
$scope.errMsg = undefined;
|
||||||
resolve();
|
resolve();
|
||||||
|
|
||||||
}).then(function() {
|
}).then(function() {
|
||||||
@ -29,7 +30,7 @@ var PublicKeyVerifierCtrl = function($scope, $location, $q, $timeout, $interval,
|
|||||||
return success();
|
return success();
|
||||||
|
|
||||||
}).catch(function(error) {
|
}).catch(function(error) {
|
||||||
$scope.errMsg = error.message; // display error
|
$scope.errMsg = error.message + ' Retrying in ' + RETRY_INTERVAL / 1000 + ' seconds...'; // display error
|
||||||
|
|
||||||
scheduleVerification(); // schedule next verification attempt
|
scheduleVerification(); // schedule next verification attempt
|
||||||
});
|
});
|
||||||
|
@ -95,7 +95,7 @@ PublickeyVerifier.prototype.verify = function() {
|
|||||||
|
|
||||||
if (!verificationSuccessful) {
|
if (!verificationSuccessful) {
|
||||||
// nothing unexpected went wrong, but no public key could be verified
|
// nothing unexpected went wrong, but no public key could be verified
|
||||||
throw new Error('Could not verify public key');
|
throw new Error('Could not verify public key.');
|
||||||
}
|
}
|
||||||
|
|
||||||
resolve(); // we're done
|
resolve(); // we're done
|
||||||
|
Loading…
Reference in New Issue
Block a user