Skip to content

Commit

Permalink
more linting
Browse files Browse the repository at this point in the history
  • Loading branch information
patrick-ogrady committed Sep 16, 2021
1 parent aa09e49 commit 12feada
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion mapper/amount.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ func Amount(value *big.Int, currency *types.Currency) *types.Amount {

func FeeAmount(value int64) *types.Amount {
return &types.Amount{
Value: strconv.FormatInt(value, 10),
Value: strconv.FormatInt(value, 10), //nolint:gomnd
Currency: AvaxCurrency,
}
}
Expand Down
4 changes: 2 additions & 2 deletions service/service_construction.go
Original file line number Diff line number Diff line change
Expand Up @@ -491,7 +491,7 @@ func (s ConstructionService) ConstructionPreprocess(
if !ok {
return nil, wrapError(errInvalidInput, fmt.Errorf("%s is not a valid gas price string", v))
}
bigObj, ok := new(big.Int).SetString(stringObj, 10)
bigObj, ok := new(big.Int).SetString(stringObj, 10) //nolint:gomnd
if !ok {
return nil, wrapError(errInvalidInput, fmt.Errorf("%s is not a valid gas price", v))
}
Expand All @@ -502,7 +502,7 @@ func (s ConstructionService) ConstructionPreprocess(
if !ok {
return nil, wrapError(errInvalidInput, fmt.Errorf("%s is not a valid nonce string", v))
}
bigObj, ok := new(big.Int).SetString(stringObj, 10)
bigObj, ok := new(big.Int).SetString(stringObj, 10) //nolint:gomnd
if !ok {
return nil, wrapError(errInvalidInput, fmt.Errorf("%s is not a valid nonce", v))
}
Expand Down
4 changes: 2 additions & 2 deletions service/types.go
Original file line number Diff line number Diff line change
Expand Up @@ -225,7 +225,7 @@ type accountMetadataWire struct {

func (m *accountMetadata) MarshalJSON() ([]byte, error) {
mw := &accountMetadataWire{
Nonce: strconv.FormatUint(m.Nonce, 10),
Nonce: strconv.FormatUint(m.Nonce, 10), //nolint:gomnd
}

return json.Marshal(mw)
Expand All @@ -237,7 +237,7 @@ func (m *accountMetadata) UnmarshalJSON(data []byte) error {
return err
}

nonce, err := strconv.ParseUint(mw.Nonce, 10, 64)
nonce, err := strconv.ParseUint(mw.Nonce, 10, 64) //nolint:gomnd
if err != nil {
return err
}
Expand Down

0 comments on commit 12feada

Please sign in to comment.