Skip to content

Commit

Permalink
format code
Browse files Browse the repository at this point in the history
  • Loading branch information
avery committed Dec 9, 2024
1 parent bf3dda8 commit 4fa6679
Show file tree
Hide file tree
Showing 5 changed files with 11 additions and 5 deletions.
6 changes: 4 additions & 2 deletions app/app.go
Original file line number Diff line number Diff line change
Expand Up @@ -236,9 +236,11 @@ func (app *IrisApp) EndBlocker(ctx sdk.Context) (sdk.EndBlock, error) {
func (app *IrisApp) InitChainer(ctx sdk.Context, req *abci.RequestInitChain) (*abci.ResponseInitChain, error) {
var genesisState iristypes.GenesisState
if err := tmjson.Unmarshal(req.AppStateBytes, &genesisState); err != nil {
panic(err)
return nil, err
}
if err := app.UpgradeKeeper.SetModuleVersionMap(ctx, app.mm.GetVersionMap()); err != nil {
return nil, err
}
app.UpgradeKeeper.SetModuleVersionMap(ctx, app.mm.GetVersionMap())
return app.mm.InitGenesis(ctx, app.appCodec, genesisState)
}

Expand Down
6 changes: 4 additions & 2 deletions app/export.go
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,9 @@ func (app *IrisApp) prepForZeroHeightGenesis(ctx sdk.Context, jailAllowedAddrs [
app.StakingKeeper.IterateValidators(
ctx,
func(_ int64, val stakingtypes.ValidatorI) (stop bool) {
_, _ = app.DistrKeeper.WithdrawValidatorCommission(ctx, sdk.ValAddress(val.GetOperator()))
if _, err := app.DistrKeeper.WithdrawValidatorCommission(ctx, sdk.ValAddress(val.GetOperator())); err != nil {
panic(err)
}
return false
},
)
Expand Down Expand Up @@ -226,7 +228,7 @@ func (app *IrisApp) prepForZeroHeightGenesis(ctx sdk.Context, jailAllowedAddrs [

_, err = app.StakingKeeper.ApplyAndReturnValidatorSetUpdates(ctx)
if err != nil {
log.Fatal(err)
panic(err)
}

/* Handle slashing state. */
Expand Down
2 changes: 2 additions & 0 deletions modules/internft/interface.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,11 @@ package internft

import (
"context"

nftkeeper "cosmossdk.io/x/nft/keeper"
"github.com/cosmos/cosmos-sdk/codec"
sdk "github.com/cosmos/cosmos-sdk/types"

nfttypes "mods.irisnet.org/modules/nft/types"
)

Expand Down
1 change: 0 additions & 1 deletion modules/mint/keeper/keeper.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ import (
"fmt"

"cosmossdk.io/log"

storetypes "cosmossdk.io/store/types"
"github.com/cosmos/cosmos-sdk/codec"
sdk "github.com/cosmos/cosmos-sdk/types"
Expand Down
1 change: 1 addition & 0 deletions wrapper/farm.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ package wrapper

import (
"context"

"github.com/cosmos/cosmos-sdk/types"
govtypes "github.com/cosmos/cosmos-sdk/x/gov/types"

Expand Down

0 comments on commit 4fa6679

Please sign in to comment.