Skip to content

Commit

Permalink
dont override balances in import-genesis-account-from-snapshot (osmos…
Browse files Browse the repository at this point in the history
  • Loading branch information
sunnya97 authored Jun 4, 2021
1 parent b758cc7 commit a86a172
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions cmd/osmosisd/cmd/genaccounts.go
Original file line number Diff line number Diff line change
Expand Up @@ -241,7 +241,9 @@ Example:
normalizationFactor := genesisParams.AirdropSupply.ToDec().QuoInt(snapshot.TotalOsmosAirdropAmount)
fmt.Printf("normalization factor: %s\n", normalizationFactor)

liquidBalances := []banktypes.Balance{}
bankGenState := banktypes.GetGenesisStateFromAppState(cdc, appState)

liquidBalances := bankGenState.Balances
claimRecords := []claimtypes.ClaimRecord{}
claimModuleAccountBalance := sdk.NewInt(0)

Expand Down Expand Up @@ -307,7 +309,6 @@ Example:
appState[authtypes.ModuleName] = authGenStateBz

// bank module genesis
bankGenState := banktypes.GetGenesisStateFromAppState(depCdc, appState)
bankGenState.Balances = banktypes.SanitizeGenesisBalances(liquidBalances)
bankGenStateBz, err := cdc.MarshalJSON(bankGenState)
if err != nil {
Expand Down

0 comments on commit a86a172

Please sign in to comment.