aboutsummaryrefslogtreecommitdiff
path: root/lib/wallet/wxMessaging.ts
diff options
context:
space:
mode:
authorFlorian Dold <florian.dold@gmail.com>2016-05-24 17:30:27 +0200
committerFlorian Dold <florian.dold@gmail.com>2016-05-24 17:30:27 +0200
commit27a42f92572abfdb2e60f3f212e4f0fcc71a6961 (patch)
treecb07ba11b01b05baccbbec0d58b231d1d8c237f7 /lib/wallet/wxMessaging.ts
parentce7f7b8321c89f9bdd62e9b148181865f8834871 (diff)
downloadwallet-core-27a42f92572abfdb2e60f3f212e4f0fcc71a6961.tar.xz
respond to failed payments
Diffstat (limited to 'lib/wallet/wxMessaging.ts')
-rw-r--r--lib/wallet/wxMessaging.ts8
1 files changed, 8 insertions, 0 deletions
diff --git a/lib/wallet/wxMessaging.ts b/lib/wallet/wxMessaging.ts
index 522a87285..d5c32229d 100644
--- a/lib/wallet/wxMessaging.ts
+++ b/lib/wallet/wxMessaging.ts
@@ -141,6 +141,13 @@ function makeHandlers(db: IDBDatabase,
// TODO: limit history length
return wallet.getHistory();
},
+ ["payment-failed"]: function(detail, sender) {
+ // For now we just update exchanges (maybe the exchange did something
+ // wrong and the keys were messed up).
+ // FIXME: in the future we should look at what actually went wrong.
+ wallet.updateExchanges();
+ return Promise.resolve();
+ },
};
}
@@ -155,6 +162,7 @@ class ChromeBadge implements Badge {
}
startBusy() {
+ this.setColor("#00F");
this.setText("...");
}