From cb607b4911711501a8e70db0fe2148c51272c719 Mon Sep 17 00:00:00 2001 From: Marek Kotewicz Date: Wed, 29 Oct 2014 17:14:59 +0100 Subject: changes to make whisper working --- main.js | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) (limited to 'main.js') diff --git a/main.js b/main.js index 32064ce26..cc85b9850 100644 --- a/main.js +++ b/main.js @@ -131,11 +131,11 @@ }).then(function (request) { return new Promise(function (resolve, reject) { web3.provider.send(request, function (result) { - if (result) { + if (result || typeof result === "boolean") { resolve(result); - } else { - reject(result); - } + return; + } + reject(result); }); }); }).catch(function( err) { @@ -373,6 +373,10 @@ }); }; + Filter.prototype.arrived = function(callback) { + this.changed(callback); + } + Filter.prototype.changed = function(callback) { var self = this; this.promise.then(function(id) { -- cgit v1.2.3