mirror of
https://github.com/tendermint/tendermint.git
synced 2026-09-21 07:24:36 +00:00
tmsp: ResponseInfo and ResponseEndBlock
This commit is contained in:
+10
-2
@@ -12,6 +12,14 @@ func TMSPQuery(query []byte) (*ctypes.ResultTMSPQuery, error) {
|
||||
}
|
||||
|
||||
func TMSPInfo() (*ctypes.ResultTMSPInfo, error) {
|
||||
res, tmspInfo, lastBlockInfo, configInfo := proxyAppQuery.InfoSync()
|
||||
return &ctypes.ResultTMSPInfo{res, tmspInfo, lastBlockInfo, configInfo}, nil
|
||||
res, err := proxyAppQuery.InfoSync()
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return &ctypes.ResultTMSPInfo{
|
||||
Data: res.Data,
|
||||
Version: res.Version,
|
||||
LastBlockHeight: res.LastBlockHeight,
|
||||
LastBlockAppHash: res.LastBlockAppHash,
|
||||
}, nil
|
||||
}
|
||||
|
||||
@@ -74,10 +74,10 @@ type ResultUnconfirmedTxs struct {
|
||||
}
|
||||
|
||||
type ResultTMSPInfo struct {
|
||||
Result tmsp.Result `json:"result"`
|
||||
TMSPInfo *tmsp.TMSPInfo `json:"tmsp_info"`
|
||||
LastBlockInfo *tmsp.LastBlockInfo `json:"last_block_info"`
|
||||
ConfigInfo *tmsp.ConfigInfo `json:"config_info"`
|
||||
Data string `json:"data"`
|
||||
Version string `json:"version"`
|
||||
LastBlockHeight uint64 `json:"last_block_height"`
|
||||
LastBlockAppHash []byte `json:"last_block_app_hash"`
|
||||
}
|
||||
|
||||
type ResultTMSPQuery struct {
|
||||
|
||||
Reference in New Issue
Block a user