From f3e78e50ff5c02b9b365de0571f1782b205cb319 Mon Sep 17 00:00:00 2001 From: Marek Kotewicz Date: Wed, 21 Jan 2015 18:56:30 +0100 Subject: [PATCH] changes to for natspec --- index.js | 1 + lib/contract.js | 3 ++- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/index.js b/index.js index e0382a8a42..0c5bf3d441 100644 --- a/index.js +++ b/index.js @@ -7,5 +7,6 @@ web3.providers.HttpRpcProvider = require('./lib/httprpc'); web3.providers.QtProvider = require('./lib/qt'); web3.providers.AutoProvider = require('./lib/autoprovider'); web3.eth.contract = require('./lib/contract'); +web3.abi = require('./lib/abi'); module.exports = web3; diff --git a/lib/contract.js b/lib/contract.js index 67fb407ad9..abd8e5bdfd 100644 --- a/lib/contract.js +++ b/lib/contract.js @@ -79,7 +79,8 @@ var contract = function (address, desc) { extra.to = address; return abi.methodSignature(desc, method.name).then(function (signature) { extra.data = signature.slice(0, 2 + ETH_METHOD_SIGNATURE_LENGTH * 2) + parsed; - web3._currentAbi = desc; + web3._currentContractAbi = desc; + web3._currentContractAddress = address; return web3.eth.transact(extra).then(onSuccess); }); }