Skip to content

Commit

Permalink
Delete unnecessary if (#1719)
Browse files Browse the repository at this point in the history
  • Loading branch information
dusannosovic-ethernal committed Jul 14, 2023
1 parent 6c47248 commit da7ad74
Showing 1 changed file with 1 addition and 7 deletions.
8 changes: 1 addition & 7 deletions command/genesis/params.go
Original file line number Diff line number Diff line change
Expand Up @@ -500,20 +500,14 @@ func (p *genesisParams) parsePremineInfo() error {

// validatePremineInfo validates whether reserve account (0x0 address) is premined
func (p *genesisParams) validatePremineInfo() error {
isReserveAccPremined := false

for _, premineInfo := range p.premineInfos {
if premineInfo.address == types.ZeroAddress {
// we have premine of zero address, just return
return nil
}
}

if !isReserveAccPremined {
return errReserveAccMustBePremined
}

return nil
return errReserveAccMustBePremined
}

// validateBurnContract validates burn contract. If native token is mintable,
Expand Down

0 comments on commit da7ad74

Please sign in to comment.