From c013192ba7683741b33ad3f713c0b83d0a619b31 Mon Sep 17 00:00:00 2001 From: Felix Lange Date: Tue, 19 Nov 2019 14:53:26 +0100 Subject: [PATCH] ethclient: remove use of common.ToHex (#20326) --- ethclient/ethclient.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ethclient/ethclient.go b/ethclient/ethclient.go index 0a6f73ab51..a60d732231 100644 --- a/ethclient/ethclient.go +++ b/ethclient/ethclient.go @@ -514,7 +514,7 @@ func (ec *Client) SendTransaction(ctx context.Context, tx *types.Transaction) er if err != nil { return err } - return ec.c.CallContext(ctx, nil, "eth_sendRawTransaction", common.ToHex(data)) + return ec.c.CallContext(ctx, nil, "eth_sendRawTransaction", hexutil.Encode(data)) } func toCallArg(msg ethereum.CallMsg) interface{} {