Skip to content

Commit

Permalink
chore: Remove unused evmkeeper.New params
Browse files Browse the repository at this point in the history
  • Loading branch information
drklee3 committed Apr 16, 2024
1 parent 0a60c6c commit 2518023
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 14 deletions.
1 change: 0 additions & 1 deletion app/app.go
Original file line number Diff line number Diff line change
Expand Up @@ -426,7 +426,6 @@ func NewEthermintApp(
app.EvmKeeper = evmkeeper.NewKeeper(
appCodec,
keys[evmtypes.StoreKey], tkeys[evmtypes.TransientKey],
keys[banktypes.StoreKey], nil,
authtypes.NewModuleAddress(govtypes.ModuleName),
app.AccountKeeper, app.BankKeeper, app.StakingKeeper, app.FeeMarketKeeper,
nil, geth.NewEVM, tracer, evmSs,
Expand Down
9 changes: 0 additions & 9 deletions x/evm/keeper/keeper.go
Original file line number Diff line number Diff line change
Expand Up @@ -49,12 +49,6 @@ type Keeper struct {
// - storing Bloom filters by block height. Needed for the Web3 API.
storeKey storetypes.StoreKey

// Bank store key is required for StateDB state compatibility purposes,
// used only for removing dirty state from the cachekv for no-op balance
// changes.
bankStoreKey storetypes.StoreKey
evmutilStoreKey storetypes.StoreKey

// key to access the transient store, which is reset on every block during Commit
transientKey storetypes.StoreKey

Expand Down Expand Up @@ -92,7 +86,6 @@ type Keeper struct {
func NewKeeper(
cdc codec.BinaryCodec,
storeKey, transientKey storetypes.StoreKey,
bankStoreKey, evmutilStoreKey storetypes.StoreKey,
authority sdk.AccAddress,
ak types.AccountKeeper,
bankKeeper types.BankKeeper,
Expand Down Expand Up @@ -127,8 +120,6 @@ func NewKeeper(
feeMarketKeeper: fmk,
storeKey: storeKey,
transientKey: transientKey,
bankStoreKey: bankStoreKey,
evmutilStoreKey: evmutilStoreKey,
customPrecompiles: customPrecompiles,
evmConstructor: evmConstructor,
tracer: tracer,
Expand Down
6 changes: 3 additions & 3 deletions x/evm/keeper/params_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,7 @@ func (suite *KeeperTestSuite) TestLegacyParamsKeyTableRegistration() {
newKeeper := func() *keeper.Keeper {
// create a keeper, mimicking an app.go which has not registered the key table
return keeper.NewKeeper(
cdc, storeKey, tKey, nil, nil, authtypes.NewModuleAddress("gov"),
cdc, storeKey, tKey, authtypes.NewModuleAddress("gov"),
ak,
nil, nil, nil, nil, // OK to pass nil in for these since we only instantiate and use params
geth.NewEVM,
Expand Down Expand Up @@ -205,7 +205,7 @@ func (suite *KeeperTestSuite) TestRenamedFieldReturnsProperValueForLegacyParams(
"evm",
)
k := keeper.NewKeeper(
cdc, storeKey, tKey, nil, nil, authtypes.NewModuleAddress("gov"),
cdc, storeKey, tKey, authtypes.NewModuleAddress("gov"),
ak,
nil, nil, nil, nil,
geth.NewEVM,
Expand Down Expand Up @@ -238,7 +238,7 @@ func (suite *KeeperTestSuite) TestNilLegacyParamsDoNotPanic() {
)

k := keeper.NewKeeper(
cdc, storeKey, tKey, nil, nil, authtypes.NewModuleAddress("gov"),
cdc, storeKey, tKey, authtypes.NewModuleAddress("gov"),
ak,
nil, nil, nil, nil, // OK to pass nil in for these since we only instantiate and use params
geth.NewEVM,
Expand Down
2 changes: 1 addition & 1 deletion x/evm/migrations/v3/store_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,7 @@ func TestKeyTableCompatiabilityWithKeeper(t *testing.T) {
"evm",
)
keeper.NewKeeper(
cdc, storeKey, tKey, nil, nil, authtypes.NewModuleAddress("gov"),
cdc, storeKey, tKey, authtypes.NewModuleAddress("gov"),
ak,
nil, nil, nil, nil,
geth.NewEVM,
Expand Down

0 comments on commit 2518023

Please sign in to comment.