diff --git a/CHANGELOG.md b/CHANGELOG.md index 93f045160ed..8eca4b873b9 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -39,6 +39,7 @@ Ref: https://keepachangelog.com/en/1.0.0/ ### Improvements +* (baseapp) [#17954](https://github.com/cosmos/cosmos-sdk/issues/17954) Add `Mempool()` method on `BaseApp` to allow access to the mempool. * (x/gov) [#17780](https://github.com/cosmos/cosmos-sdk/pull/17780) Recover panics and turn them into errors when executing x/gov proposals. ### Bug Fixes diff --git a/baseapp/baseapp.go b/baseapp/baseapp.go index 7c82ff493de..c2ce465ca9c 100644 --- a/baseapp/baseapp.go +++ b/baseapp/baseapp.go @@ -351,6 +351,11 @@ func (app *BaseApp) LastBlockHeight() int64 { return app.cms.LastCommitID().Version } +// Mempool returns the Mempool of the app. +func (app *BaseApp) Mempool() mempool.Mempool { + return app.mempool +} + // Init initializes the app. It seals the app, preventing any // further modifications. In addition, it validates the app against // the earlier provided settings. Returns an error if validation fails.