update uncles return (#337)
This commit is contained in:
parent
9f573690a6
commit
0921c863e7
@ -545,7 +545,7 @@ func formatBlock(
|
|||||||
"gasUsed": (*hexutil.Big)(gasUsed),
|
"gasUsed": (*hexutil.Big)(gasUsed),
|
||||||
"timestamp": hexutil.Uint64(header.Time.Unix()),
|
"timestamp": hexutil.Uint64(header.Time.Unix()),
|
||||||
"transactions": transactions.([]common.Hash),
|
"transactions": transactions.([]common.Hash),
|
||||||
"uncles": nil,
|
"uncles": []string{},
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -763,4 +763,5 @@ func TestEth_GetBlockByNumber(t *testing.T) {
|
|||||||
err := json.Unmarshal(rpcRes.Result, &block)
|
err := json.Unmarshal(rpcRes.Result, &block)
|
||||||
require.NoError(t, err)
|
require.NoError(t, err)
|
||||||
require.Equal(t, "0x0", block["extraData"].(string))
|
require.Equal(t, "0x0", block["extraData"].(string))
|
||||||
|
require.Equal(t, []interface{}{}, block["uncles"].([]interface{}))
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user