Fix coinswitch issue

Coinswitch did a breaking change, this fixes it. Closes #660
This commit is contained in:
Kukks
2019-03-09 14:09:31 +01:00
parent 3c7d93e88d
commit 63a975267c

View File

@@ -46,7 +46,9 @@
setTimeout(waitForCoinSwitch, 1000);
return;
}
payment.open(config);
payment.on("Exchange:Ready", function(){
payment.open(config);
});
payment.on("Exchange:Complete", function () {
if(window.localStorage){
window.localStorage.removeItem(toCurrencyAddress);