mobile: fix TransactionSender

This commit is contained in:
Felix Lange 2017-09-25 11:17:09 +02:00
parent 302bc9f7fb
commit 7db0e665c0

View file

@ -77,9 +77,10 @@ func (ec *EthereumClient) GetTransactionByHash(ctx *Context, hash *Hash) (tx *Tr
return &Transaction{rawTx}, err return &Transaction{rawTx}, err
} }
// GetTransactionSender returns the sender address of a transaction. // GetTransactionSender returns the sender address of a transaction. The transaction must
func (ec *EthereumClient) GetTransactionSender(ctx *Context, tx *Transaction) (sender *Address, _ error) { // be included in the blockchain.
addr, err := ec.client.TransactionSender(ctx.context, tx.tx) func (ec *EthereumClient) GetTransactionSender(ctx *Context, tx *Transaction, hash *Hash, index int) (sender *Address, _ error) {
addr, err := ec.client.TransactionSender(ctx.context, tx.tx, hash.hash, uint(index))
return &Address{addr}, err return &Address{addr}, err
} }