mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-07-17 18:30:45 +00:00
Missing json Field Tags in Marshalled Struct (#475)
This commit is contained in:
parent
75c8d40399
commit
910d415653
1 changed files with 10 additions and 10 deletions
|
|
@ -14,17 +14,17 @@ type Signature []byte
|
||||||
|
|
||||||
// Block Info struct in XDPoS 2.0, used for vote message, etc.
|
// Block Info struct in XDPoS 2.0, used for vote message, etc.
|
||||||
type BlockInfo struct {
|
type BlockInfo struct {
|
||||||
Hash common.Hash
|
Hash common.Hash `json:"hash"`
|
||||||
Round Round
|
Round Round `json:"round"`
|
||||||
Number *big.Int
|
Number *big.Int `json:"number"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// Vote message in XDPoS 2.0
|
// Vote message in XDPoS 2.0
|
||||||
type Vote struct {
|
type Vote struct {
|
||||||
signer common.Address
|
signer common.Address //field not exported
|
||||||
ProposedBlockInfo *BlockInfo
|
ProposedBlockInfo *BlockInfo `json:"proposedBlockInfo"`
|
||||||
Signature Signature
|
Signature Signature `json:"signature"`
|
||||||
GapNumber uint64
|
GapNumber uint64 `json:"gapNumber"`
|
||||||
}
|
}
|
||||||
|
|
||||||
func (v *Vote) Hash() common.Hash {
|
func (v *Vote) Hash() common.Hash {
|
||||||
|
|
@ -81,9 +81,9 @@ func (s *SyncInfo) Hash() common.Hash {
|
||||||
|
|
||||||
// Quorum Certificate struct in XDPoS 2.0
|
// Quorum Certificate struct in XDPoS 2.0
|
||||||
type QuorumCert struct {
|
type QuorumCert struct {
|
||||||
ProposedBlockInfo *BlockInfo
|
ProposedBlockInfo *BlockInfo `json:"proposedBlockInfo"`
|
||||||
Signatures []Signature
|
Signatures []Signature `json:"signatures"`
|
||||||
GapNumber uint64
|
GapNumber uint64 `json:"gapNumber"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// Timeout Certificate struct in XDPoS 2.0
|
// Timeout Certificate struct in XDPoS 2.0
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue