From 56b20becfb9c31e6b62bbee1273fce4217f64f91 Mon Sep 17 00:00:00 2001 From: Ricardo Guilherme Schmidt <3esmit@gmail.com> Date: Fri, 18 May 2018 20:44:14 -0300 Subject: [PATCH] make getAccounts a simple web3 wrapper. Maybe could even be like Test.prototype.getAccounts = web3.eth.getAccounts; ? --- lib/tests/test.js | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/lib/tests/test.js b/lib/tests/test.js index b79f81c1..04877a8f 100644 --- a/lib/tests/test.js +++ b/lib/tests/test.js @@ -52,10 +52,7 @@ var Test = function(options) { Test.prototype.getAccounts = function(cb) { this.web3.eth.getAccounts(function(err, accounts) { - if (err) { - throw new Error(err); - } - cb(accounts); + cb(err, accounts); }); };