refactor: use FormatUint instead of converting to int. (#13582)

This commit is contained in:
Xavier Leprêtre 2022-10-18 18:40:39 +04:00 committed by GitHub
parent 1f10efe621
commit c9b446029f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 3 deletions

View File

@ -119,7 +119,7 @@ func (k msgServer) Vote(goCtx context.Context, msg *v1.MsgVote) (*v1.MsgVoteResp
[]string{govtypes.ModuleName, "vote"}, []string{govtypes.ModuleName, "vote"},
1, 1,
[]metrics.Label{ []metrics.Label{
telemetry.NewLabel("proposal_id", strconv.Itoa(int(msg.ProposalId))), telemetry.NewLabel("proposal_id", strconv.FormatUint(msg.ProposalId, 10)),
}, },
) )
@ -141,7 +141,7 @@ func (k msgServer) VoteWeighted(goCtx context.Context, msg *v1.MsgVoteWeighted)
[]string{govtypes.ModuleName, "vote"}, []string{govtypes.ModuleName, "vote"},
1, 1,
[]metrics.Label{ []metrics.Label{
telemetry.NewLabel("proposal_id", strconv.Itoa(int(msg.ProposalId))), telemetry.NewLabel("proposal_id", strconv.FormatUint(msg.ProposalId, 10)),
}, },
) )
@ -163,7 +163,7 @@ func (k msgServer) Deposit(goCtx context.Context, msg *v1.MsgDeposit) (*v1.MsgDe
[]string{govtypes.ModuleName, "deposit"}, []string{govtypes.ModuleName, "deposit"},
1, 1,
[]metrics.Label{ []metrics.Label{
telemetry.NewLabel("proposal_id", strconv.Itoa(int(msg.ProposalId))), telemetry.NewLabel("proposal_id", strconv.FormatUint(msg.ProposalId, 10)),
}, },
) )