Skip to content

Commit

Permalink
make staking keeper private
Browse files Browse the repository at this point in the history
  • Loading branch information
kingpinXD committed Feb 15, 2024
1 parent 0e36d89 commit 0499ada
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
6 changes: 3 additions & 3 deletions x/crosschain/keeper/keeper.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ type (
storeKey storetypes.StoreKey
memKey storetypes.StoreKey

StakingKeeper types.StakingKeeper
stakingKeeper types.StakingKeeper
paramstore paramtypes.Subspace
authKeeper types.AccountKeeper
bankKeeper types.BankKeeper
Expand Down Expand Up @@ -49,7 +49,7 @@ func NewKeeper(
cdc: cdc,
storeKey: storeKey,
memKey: memKey,
StakingKeeper: stakingKeeper,
stakingKeeper: stakingKeeper,
paramstore: paramstore,
authKeeper: authKeeper,
bankKeeper: bankKeeper,
Expand All @@ -71,7 +71,7 @@ func (k Keeper) GetBankKeeper() types.BankKeeper {
}

func (k Keeper) GetStakingKeeper() types.StakingKeeper {
return k.StakingKeeper
return k.stakingKeeper
}

func (k Keeper) GetFungibleKeeper() types.FungibleKeeper {
Expand Down
2 changes: 1 addition & 1 deletion x/crosschain/keeper/msg_server_gas_price_voter.go
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ func medianOfArray(values []uint64) int {

// ResetGasMeterAndConsumeGas reset first the gas meter consumed value to zero and set it back to the new value
// 'gasUsed'
func (k *Keeper) ResetGasMeterAndConsumeGas(ctx sdk.Context, gasUsed uint64) {
func (k Keeper) ResetGasMeterAndConsumeGas(ctx sdk.Context, gasUsed uint64) {
// reset the gas count
ctx.GasMeter().RefundGas(ctx.GasMeter().GasConsumed(), "reset the gas count")
ctx.GasMeter().ConsumeGas(gasUsed, "apply evm transaction")
Expand Down
4 changes: 2 additions & 2 deletions x/crosschain/keeper/msg_server_vote_inbound_tx_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ import (
)

func setObservers(t *testing.T, k *keeper.Keeper, ctx sdk.Context, zk keepertest.ZetaKeepers) []string {
validators := k.StakingKeeper.GetAllValidators(ctx)
validators := k.GetStakingKeeper().GetAllValidators(ctx)

validatorAddressListFormatted := make([]string, len(validators))
for i, validator := range validators {
Expand Down Expand Up @@ -85,7 +85,7 @@ func TestNoDoubleEventProtections(t *testing.T) {
)

// Convert the validator address into a user address.
validators := k.StakingKeeper.GetAllValidators(ctx)
validators := k.GetStakingKeeper().GetAllValidators(ctx)
validatorAddress := validators[0].OperatorAddress
valAddr, _ := sdk.ValAddressFromBech32(validatorAddress)
addresstmp, _ := sdk.AccAddressFromHexUnsafe(hex.EncodeToString(valAddr.Bytes()))
Expand Down

0 comments on commit 0499ada

Please sign in to comment.