From 18490d833cf416f476d1e4587002a3ff484f288b Mon Sep 17 00:00:00 2001 From: Bas van Kervel Date: Wed, 6 Apr 2016 10:56:37 +0200 Subject: console: use transaction output formatter for eth.pendingTransactions output --- rpc/javascript.go | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) (limited to 'rpc/javascript.go') diff --git a/rpc/javascript.go b/rpc/javascript.go index c4fa80c0b..211a6644e 100644 --- a/rpc/javascript.go +++ b/rpc/javascript.go @@ -250,7 +250,15 @@ web3._extend({ [ new web3._extend.Property({ name: 'pendingTransactions', - getter: 'eth_pendingTransactions' + getter: 'eth_pendingTransactions', + outputFormatter: function(txs) { + var formatted = []; + for (var i = 0; i < txs.length; i++) { + formatted.push(web3._extend.formatters.outputTransactionFormatter(txs[i])); + formatted[i].blockHash = null; + } + return formatted; + } }) ] }); -- cgit