fix some event handlers

This commit is contained in:
Matias Alejo Garcia 2014-12-01 15:33:16 -03:00
commit 67fd6344dd
7 changed files with 52 additions and 14 deletions

View file

@ -592,11 +592,10 @@ Identity.prototype.deleteWallet = function(walletId, cb) {
delete this.focusedTimestamps[walletId];
this.storage.removeItem(Wallet.getStorageKey(walletId), function(err) {
if (err) {
return cb(err);
}
if (err) return cb(err);
self.emitAndKeepAlive('deletedWallet', walletId);
self.store(null, cb);
return cb();
});
};