Skip to content

Commit

Permalink
change location
Browse files Browse the repository at this point in the history
  • Loading branch information
czarcas7ic committed Jun 17, 2024
1 parent d792e23 commit 8a92ab5
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 10 deletions.
10 changes: 10 additions & 0 deletions baseapp/abci.go
Original file line number Diff line number Diff line change
Expand Up @@ -412,6 +412,16 @@ func (app *BaseApp) DeliverTx(req abci.RequestDeliverTx) (res abci.ResponseDeliv
return sdkerrors.ResponseDeliverTxWithEvents(err, gInfo.GasWanted, gInfo.GasUsed, sdk.MarkEventsToIndex(anteEvents, app.indexEvents), app.trace)
}

if sdk.MaxEventSize > 0 {
for _, event := range result.Events {
for _, attr := range event.Attributes {
if len([]byte(attr.Key))+len([]byte(attr.Value)) > sdk.MaxEventSize {
attr.Value = "evt val too large, inc max-event-size in config.toml"
}
}
}
}

return abci.ResponseDeliverTx{
GasWanted: int64(gInfo.GasWanted), // TODO: Should type accept unsigned ints?
GasUsed: int64(gInfo.GasUsed), // TODO: Should type accept unsigned ints?
Expand Down
10 changes: 0 additions & 10 deletions baseapp/baseapp.go
Original file line number Diff line number Diff line change
Expand Up @@ -775,16 +775,6 @@ func (app *BaseApp) runTx(mode runTxMode, txBytes []byte) (gInfo sdk.GasInfo, re
}
}

if sdk.MaxEventSize > 0 {
for _, event := range result.Events {
for _, attr := range event.Attributes {
if len([]byte(attr.Key))+len([]byte(attr.Value)) > sdk.MaxEventSize {
attr.Value = "evt val too large, inc max-event-size in config.toml"
}
}
}
}

return gInfo, result, anteEvents, priority, err
}

Expand Down

0 comments on commit 8a92ab5

Please sign in to comment.