Fix showErrorPopup

This commit is contained in:
Gustavo Maximiliano Cortez 2015-10-28 16:39:02 -03:00
parent ca7ec8e392
commit 015e7a788e
No known key found for this signature in database
GPG Key ID: 15EDAD8D9F2EB1AF
1 changed files with 7 additions and 7 deletions

View File

@ -787,12 +787,8 @@ angular.module('copayApp.controllers').controller('indexController', function($r
self.showAlert = {
msg: msg,
close: function(err) {
if (self.isCordova && navigator && navigator.app) {
navigator.app.exitApp();
} else {
self.showAlert = null;
if (cb) return cb(err);
}
self.showAlert = null;
if (cb) return cb(err);
},
};
$timeout(function() {
@ -1054,7 +1050,11 @@ angular.module('copayApp.controllers').controller('indexController', function($r
});
$rootScope.$on('Local/DeviceError', function(event, err) {
self.showErrorPopup(err);
self.showErrorPopup(err, function() {
if (self.isCordova && navigator && navigator.app) {
navigator.app.exitApp();
}
});
});
$rootScope.$on('Local/WalletImported', function(event, walletId) {