diff options
author | Taylor Gerring <taylor.gerring@gmail.com> | 2015-04-01 19:18:30 +0800 |
---|---|---|
committer | Taylor Gerring <taylor.gerring@gmail.com> | 2015-04-01 19:18:30 +0800 |
commit | 88f2a96ca3224bf59cf5639ffc4efabe2fe1f87b (patch) | |
tree | fd01d8ab56cbcb97882a36bd81f180ce55a674d7 /rpc/responses.go | |
parent | dba9b83aa07ced653b24c3e34d55ffe13a740243 (diff) | |
download | go-tangerine-88f2a96ca3224bf59cf5639ffc4efabe2fe1f87b.tar go-tangerine-88f2a96ca3224bf59cf5639ffc4efabe2fe1f87b.tar.gz go-tangerine-88f2a96ca3224bf59cf5639ffc4efabe2fe1f87b.tar.bz2 go-tangerine-88f2a96ca3224bf59cf5639ffc4efabe2fe1f87b.tar.lz go-tangerine-88f2a96ca3224bf59cf5639ffc4efabe2fe1f87b.tar.xz go-tangerine-88f2a96ca3224bf59cf5639ffc4efabe2fe1f87b.tar.zst go-tangerine-88f2a96ca3224bf59cf5639ffc4efabe2fe1f87b.zip |
Set fullTx option in constructor
Diffstat (limited to 'rpc/responses.go')
-rw-r--r-- | rpc/responses.go | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/rpc/responses.go b/rpc/responses.go index 3e9293fbb..9e1170c32 100644 --- a/rpc/responses.go +++ b/rpc/responses.go @@ -29,12 +29,15 @@ type BlockRes struct { Uncles []*hexdata `json:"uncles"` } -func NewBlockRes(block *types.Block) *BlockRes { +func NewBlockRes(block *types.Block, fullTx bool) *BlockRes { + // TODO respect fullTx flag + if block == nil { return &BlockRes{} } res := new(BlockRes) + res.fullTx = fullTx res.BlockNumber = newHexNum(block.Number()) res.BlockHash = newHexData(block.Hash()) res.ParentHash = newHexData(block.ParentHash()) |