From a69cccca470753c96ef070ee09e531ed760b4e67 Mon Sep 17 00:00:00 2001 From: Florian Dold Date: Sat, 5 Dec 2015 16:32:31 +0100 Subject: [PATCH] Consistent names for event types. --- extension/background/wallet.js | 6 +++--- extension/content_scripts/notify.js | 7 ------- 2 files changed, 3 insertions(+), 10 deletions(-) diff --git a/extension/background/wallet.js b/extension/background/wallet.js index c6fbb5780..1e8dd6a7c 100644 --- a/extension/background/wallet.js +++ b/extension/background/wallet.js @@ -25,15 +25,15 @@ chrome.runtime.onMessage.addListener( : " from the extension")); switch (req.type) { - case "WALLET_GET": + case "db-get-wallet": DB.wallet_get (onresponse); break; - case "TRANSACTION_LIST": + case "db-list-transactions": DB.transaction_list (onresponse); break; - case "RESERVE_LIST": + case "db-list-reserves": DB.reserve_list (onresponse); break; } diff --git a/extension/content_scripts/notify.js b/extension/content_scripts/notify.js index 4f399b7f9..94356cf52 100644 --- a/extension/content_scripts/notify.js +++ b/extension/content_scripts/notify.js @@ -18,13 +18,6 @@ document.addEventListener("DOMContentLoaded", function(e) { document.body.dispatchEvent(evt); console.log("bank handshake done"); }); - document.body.addEventListener('taler-create-reserve', function(e) { - console.log("reserve creation " + JSON.stringify(e.detail)); - chrome.runtime.sendMessage({action:'new-reserve-request', detail:e.detail}, function(resp) { - console.log("got response"); - document.location.href = resp.url; - }); - }); }); console.log("Taler wallet: content page loaded");