Skip to content

Commit

Permalink
fix: TestAccountsMigration systemtest with simdv2 (backport #22673) (#…
Browse files Browse the repository at this point in the history
…22674)

Co-authored-by: Hieu Vu <[email protected]>
  • Loading branch information
mergify[bot] and hieuvubk authored Nov 28, 2024
1 parent 3c34ded commit 496ec07
Showing 1 changed file with 20 additions and 0 deletions.
20 changes: 20 additions & 0 deletions x/accounts/module.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ import (
"google.golang.org/grpc"

"cosmossdk.io/core/appmodule"
appmodulev2 "cosmossdk.io/core/appmodule/v2"
"cosmossdk.io/core/registry"
"cosmossdk.io/x/accounts/cli"
v1 "cosmossdk.io/x/accounts/v1"
Expand Down Expand Up @@ -61,6 +62,25 @@ func (am AppModule) RegisterServices(registrar grpc.ServiceRegistrar) error {
return nil
}

// RegisterQueryHandlers registers the query handlers for the accounts module.
func (am AppModule) RegisterQueryHandlers(router appmodulev2.QueryRouter) {
queryServer := NewQueryServer(am.k)

appmodulev2.RegisterMsgHandler(router, queryServer.AccountNumber)
appmodulev2.RegisterMsgHandler(router, queryServer.AccountQuery)
appmodulev2.RegisterMsgHandler(router, queryServer.AccountType)
appmodulev2.RegisterMsgHandler(router, queryServer.Schema)
}

// RegisterMsgHandlers registers the message handlers for the accounts module.
func (am AppModule) RegisterMsgHandlers(router appmodulev2.MsgRouter) {
msgServer := NewMsgServer(am.k)

appmodulev2.RegisterMsgHandler(router, msgServer.Execute)
appmodulev2.RegisterMsgHandler(router, msgServer.ExecuteBundle)
appmodulev2.RegisterMsgHandler(router, msgServer.Init)
}

// App module genesis

func (am AppModule) DefaultGenesis() json.RawMessage {
Expand Down

0 comments on commit 496ec07

Please sign in to comment.