From e5b664f1544afcbfc6a70277d08d8ee78ae55f0c Mon Sep 17 00:00:00 2001 From: Federico Kunze Date: Wed, 17 Oct 2018 14:26:25 +0200 Subject: [PATCH] fixed naming for proposal id and time --- x/gov/msgs.go | 12 ++++++------ x/gov/proposals.go | 4 ++-- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/x/gov/msgs.go b/x/gov/msgs.go index a5a68ea21d..ac2b2c1704 100644 --- a/x/gov/msgs.go +++ b/x/gov/msgs.go @@ -84,9 +84,9 @@ func (msg MsgSubmitProposal) GetSigners() []sdk.AccAddress { //----------------------------------------------------------- // MsgDeposit type MsgDeposit struct { - ProposalID int64 `json:"proposalID"` // ID of the proposal - Depositer sdk.AccAddress `json:"depositer"` // Address of the depositer - Amount sdk.Coins `json:"amount"` // Coins to add to the proposal's deposit + ProposalID int64 `json:"proposal_id"` // ID of the proposal + Depositer sdk.AccAddress `json:"depositer"` // Address of the depositer + Amount sdk.Coins `json:"amount"` // Coins to add to the proposal's deposit } func NewMsgDeposit(depositer sdk.AccAddress, proposalID int64, amount sdk.Coins) MsgDeposit { @@ -145,9 +145,9 @@ func (msg MsgDeposit) GetSigners() []sdk.AccAddress { //----------------------------------------------------------- // MsgVote type MsgVote struct { - ProposalID int64 // proposalID of the proposal - Voter sdk.AccAddress // address of the voter - Option VoteOption // option from OptionSet chosen by the voter + ProposalID int64 `json:"proposal_id"` // ID of the proposal + Voter sdk.AccAddress `json:"voter"` // address of the voter + Option VoteOption `json:"option"` // option from OptionSet chosen by the voter } func NewMsgVote(voter sdk.AccAddress, proposalID int64, option VoteOption) MsgVote { diff --git a/x/gov/proposals.go b/x/gov/proposals.go index 37e29df704..9d1ba860ad 100644 --- a/x/gov/proposals.go +++ b/x/gov/proposals.go @@ -68,10 +68,10 @@ type TextProposal struct { Status ProposalStatus `json:"proposal_status"` // Status of the Proposal {Pending, Active, Passed, Rejected} TallyResult TallyResult `json:"tally_result"` // Result of Tallys - SubmitTime time.Time `json:"submit_block"` // Height of the block where TxGovSubmitProposal was included + SubmitTime time.Time `json:"submit_time"` // Height of the block where TxGovSubmitProposal was included TotalDeposit sdk.Coins `json:"total_deposit"` // Current deposit on this proposal. Initial value is set at InitialDeposit - VotingStartTime time.Time `json:"voting_start_block"` // Height of the block where MinDeposit was reached. -1 if MinDeposit is not reached + VotingStartTime time.Time `json:"voting_start_time"` // Height of the block where MinDeposit was reached. -1 if MinDeposit is not reached } // Implements Proposal Interface