From 58f218bde6749a56bd145bb98ddc6633bddecaf3 Mon Sep 17 00:00:00 2001 From: C H Date: Tue, 16 Jul 2024 20:03:06 +0800 Subject: [PATCH 1/2] Updated modules initialisations --- app/modules.go | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/app/modules.go b/app/modules.go index 72051966..6a24809b 100644 --- a/app/modules.go +++ b/app/modules.go @@ -268,6 +268,7 @@ func orderEndBlockers() []string { func orderInitBlockers() []string { return []string{ capabilitytypes.ModuleName, + authtypes.ModuleName, banktypes.ModuleName, distrtypes.ModuleName, stakingtypes.ModuleName, @@ -275,21 +276,20 @@ func orderInitBlockers() []string { govtypes.ModuleName, minttypes.ModuleName, crisistypes.ModuleName, - ibctransfertypes.ModuleName, - ibcexported.ModuleName, + genutiltypes.ModuleName, evidencetypes.ModuleName, - consensusparamtypes.ModuleName, - liquiditytypes.ModuleName, - feegrant.ModuleName, authz.ModuleName, - authtypes.ModuleName, - genutiltypes.ModuleName, paramstypes.ModuleName, upgradetypes.ModuleName, vestingtypes.ModuleName, + feegrant.ModuleName, + consensusparamtypes.ModuleName, + // additional modules + ibctransfertypes.ModuleName, + ibcexported.ModuleName, + liquiditytypes.ModuleName, ibcfeetypes.ModuleName, tokenfactorytypes.ModuleName, - wasm.ModuleName, bandwidthtypes.ModuleName, ranktypes.ModuleName, From 551c2a908e702ea1025905a5d4e938a2e31b3914 Mon Sep 17 00:00:00 2001 From: C H Date: Tue, 16 Jul 2024 20:03:35 +0800 Subject: [PATCH 2/2] Fixed tokenfactory module account creation --- x/tokenfactory/keeper/keeper.go | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/x/tokenfactory/keeper/keeper.go b/x/tokenfactory/keeper/keeper.go index 0f9746e4..c9816901 100644 --- a/x/tokenfactory/keeper/keeper.go +++ b/x/tokenfactory/keeper/keeper.go @@ -96,6 +96,8 @@ func (k Keeper) GetCreatorsPrefixStore(ctx sdk.Context) sdk.KVStore { // it purely mints and burns them on behalf of the admin of respective denoms, // and sends to the relevant address. func (k Keeper) CreateModuleAccount(ctx sdk.Context) { - moduleAcc := authtypes.NewEmptyModuleAccount(types.ModuleName, authtypes.Minter, authtypes.Burner) - k.accountKeeper.SetModuleAccount(ctx, moduleAcc) + // NOTE this was wrong original code witch set tokenfactory account number to 0 + //moduleAcc := authtypes.NewEmptyModuleAccount(types.ModuleName, authtypes.Minter, authtypes.Burner) + //k.accountKeeper.SetModuleAccount(ctx, moduleAcc) + k.accountKeeper.GetModuleAccount(ctx, types.ModuleName) }