refactor: remove `indexEventsStr` from `setAnteHandler` (#12426)
This commit is contained in:
parent
4675cb54f3
commit
ff3947a344
|
@ -199,25 +199,25 @@ func NewSimApp(
|
||||||
|
|
||||||
if err := depinject.Inject(appConfig,
|
if err := depinject.Inject(appConfig,
|
||||||
&appBuilder,
|
&appBuilder,
|
||||||
&app.ParamsKeeper,
|
|
||||||
&app.CapabilityKeeper,
|
|
||||||
&app.appCodec,
|
&app.appCodec,
|
||||||
&app.legacyAmino,
|
&app.legacyAmino,
|
||||||
&app.interfaceRegistry,
|
&app.interfaceRegistry,
|
||||||
&app.AccountKeeper,
|
&app.AccountKeeper,
|
||||||
&app.BankKeeper,
|
&app.BankKeeper,
|
||||||
&app.AuthzKeeper,
|
&app.CapabilityKeeper,
|
||||||
&app.FeeGrantKeeper,
|
|
||||||
&app.StakingKeeper,
|
&app.StakingKeeper,
|
||||||
&app.GroupKeeper,
|
|
||||||
&app.NFTKeeper,
|
|
||||||
&app.SlashingKeeper,
|
&app.SlashingKeeper,
|
||||||
&app.MintKeeper,
|
&app.MintKeeper,
|
||||||
&app.EvidenceKeeper,
|
|
||||||
&app.DistrKeeper,
|
&app.DistrKeeper,
|
||||||
&app.UpgradeKeeper,
|
|
||||||
&app.GovKeeper,
|
&app.GovKeeper,
|
||||||
&app.CrisisKeeper,
|
&app.CrisisKeeper,
|
||||||
|
&app.UpgradeKeeper,
|
||||||
|
&app.ParamsKeeper,
|
||||||
|
&app.AuthzKeeper,
|
||||||
|
&app.EvidenceKeeper,
|
||||||
|
&app.FeeGrantKeeper,
|
||||||
|
&app.GroupKeeper,
|
||||||
|
&app.NFTKeeper,
|
||||||
); err != nil {
|
); err != nil {
|
||||||
panic(err)
|
panic(err)
|
||||||
}
|
}
|
||||||
|
|
|
@ -451,7 +451,7 @@ func NewSimApp(
|
||||||
app.SetInitChainer(app.InitChainer)
|
app.SetInitChainer(app.InitChainer)
|
||||||
app.SetBeginBlocker(app.BeginBlocker)
|
app.SetBeginBlocker(app.BeginBlocker)
|
||||||
app.SetEndBlocker(app.EndBlocker)
|
app.SetEndBlocker(app.EndBlocker)
|
||||||
app.setAnteHandler(encodingConfig.TxConfig, cast.ToStringSlice(appOpts.Get(server.FlagIndexEvents)))
|
app.setAnteHandler(encodingConfig.TxConfig)
|
||||||
// In v0.46, the SDK introduces _postHandlers_. PostHandlers are like
|
// In v0.46, the SDK introduces _postHandlers_. PostHandlers are like
|
||||||
// antehandlers, but are run _after_ the `runMsgs` execution. They are also
|
// antehandlers, but are run _after_ the `runMsgs` execution. They are also
|
||||||
// defined as a chain, and have the same signature as antehandlers.
|
// defined as a chain, and have the same signature as antehandlers.
|
||||||
|
@ -481,11 +481,7 @@ func NewSimApp(
|
||||||
return app
|
return app
|
||||||
}
|
}
|
||||||
|
|
||||||
func (app *SimApp) setAnteHandler(txConfig client.TxConfig, indexEventsStr []string) {
|
func (app *SimApp) setAnteHandler(txConfig client.TxConfig) {
|
||||||
indexEvents := map[string]struct{}{}
|
|
||||||
for _, e := range indexEventsStr {
|
|
||||||
indexEvents[e] = struct{}{}
|
|
||||||
}
|
|
||||||
anteHandler, err := ante.NewAnteHandler(
|
anteHandler, err := ante.NewAnteHandler(
|
||||||
ante.HandlerOptions{
|
ante.HandlerOptions{
|
||||||
AccountKeeper: app.AccountKeeper,
|
AccountKeeper: app.AccountKeeper,
|
||||||
|
|
Loading…
Reference in New Issue