mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-07-20 11:46:44 +00:00
ethapi: fix parameter types for timeout in api
This commit is contained in:
parent
631865ebdd
commit
81a65831c4
2 changed files with 2 additions and 2 deletions
|
|
@ -1661,7 +1661,7 @@ func (api *TransactionAPI) SendRawTransaction(ctx context.Context, input hexutil
|
||||||
|
|
||||||
// SendRawTransactionSync will add the signed transaction to the transaction pool
|
// SendRawTransactionSync will add the signed transaction to the transaction pool
|
||||||
// and wait until the transaction has been included in a block and return the receipt, or the timeout.
|
// and wait until the transaction has been included in a block and return the receipt, or the timeout.
|
||||||
func (api *TransactionAPI) SendRawTransactionSync(ctx context.Context, input hexutil.Bytes, timeoutMs *hexutil.Uint64) (map[string]interface{}, error) {
|
func (api *TransactionAPI) SendRawTransactionSync(ctx context.Context, input hexutil.Bytes, timeoutMs *uint64) (map[string]interface{}, error) {
|
||||||
tx := new(types.Transaction)
|
tx := new(types.Transaction)
|
||||||
if err := tx.UnmarshalBinary(input); err != nil {
|
if err := tx.UnmarshalBinary(input); err != nil {
|
||||||
return nil, err
|
return nil, err
|
||||||
|
|
|
||||||
|
|
@ -4026,7 +4026,7 @@ func TestSendRawTransactionSync_Timeout(t *testing.T) {
|
||||||
|
|
||||||
raw, _ := makeSelfSignedRaw(t, api, b.acc.Address)
|
raw, _ := makeSelfSignedRaw(t, api, b.acc.Address)
|
||||||
|
|
||||||
timeout := hexutil.Uint64(200) // 200ms
|
timeout := uint64(200) // 200ms
|
||||||
receipt, err := api.SendRawTransactionSync(context.Background(), raw, &timeout)
|
receipt, err := api.SendRawTransactionSync(context.Background(), raw, &timeout)
|
||||||
|
|
||||||
if receipt != nil {
|
if receipt != nil {
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue