소스 검색

ineternal/ethapi: wrap block size with hex.Uint64 (#19885)

gary rong 6 년 전
부모
커밋
e4232c153b
1개의 변경된 파일1개의 추가작업 그리고 1개의 파일을 삭제
  1. 1 1
      internal/ethapi/api.go

+ 1 - 1
internal/ethapi/api.go

@@ -991,7 +991,7 @@ func RPCMarshalHeader(head *types.Header) map[string]interface{} {
 // transaction hashes.
 func RPCMarshalBlock(block *types.Block, inclTx bool, fullTx bool) (map[string]interface{}, error) {
 	fields := RPCMarshalHeader(block.Header())
-	fields["size"] = block.Size()
+	fields["size"] = hexutil.Uint64(block.Size())
 
 	if inclTx {
 		formatTx := func(tx *types.Transaction) (interface{}, error) {