Compare commits
No commits in common. "f24ea80cde27161f56fb972ffd92d276aaa8a735" and "343495f6e7439042c5d50c28b0be6a9e67966014" have entirely different histories.
f24ea80cde
...
343495f6e7
1 changed files with 2 additions and 4 deletions
|
@ -256,8 +256,7 @@ instance FromJSON RpcError where
|
||||||
-- ** `zcashd`
|
-- ** `zcashd`
|
||||||
-- | Type to represent response from the `zcashd` RPC `getblock` method
|
-- | Type to represent response from the `zcashd` RPC `getblock` method
|
||||||
data BlockResponse = BlockResponse
|
data BlockResponse = BlockResponse
|
||||||
{ bl_hash :: !HexString
|
{ bl_confirmations :: !Integer -- ^ Block confirmations
|
||||||
, bl_confirmations :: !Integer -- ^ Block confirmations
|
|
||||||
, bl_height :: !Integer -- ^ Block height
|
, bl_height :: !Integer -- ^ Block height
|
||||||
, bl_time :: !Integer -- ^ Block time
|
, bl_time :: !Integer -- ^ Block time
|
||||||
, bl_txs :: ![HexString] -- ^ List of transaction IDs in the block
|
, bl_txs :: ![HexString] -- ^ List of transaction IDs in the block
|
||||||
|
@ -270,8 +269,7 @@ instance FromJSON BlockResponse where
|
||||||
h <- obj .: "height"
|
h <- obj .: "height"
|
||||||
t <- obj .:? "time"
|
t <- obj .:? "time"
|
||||||
txs <- obj .: "tx"
|
txs <- obj .: "tx"
|
||||||
hash <- obj .: "hash"
|
pure $ BlockResponse c h (fromMaybe 0 t) txs
|
||||||
pure $ BlockResponse hash c h (fromMaybe 0 t) txs
|
|
||||||
|
|
||||||
-- | Type to represent response from the `zcashd` RPC `getrawtransaction`
|
-- | Type to represent response from the `zcashd` RPC `getrawtransaction`
|
||||||
data RawTxResponse = RawTxResponse
|
data RawTxResponse = RawTxResponse
|
||||||
|
|
Loading…
Reference in a new issue