Skip to content

Commit 660e601

Browse files
committed
rename
1 parent 2ac9275 commit 660e601

File tree

3 files changed

+8
-8
lines changed

3 files changed

+8
-8
lines changed

x/bank/v2/depinject.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ type ModuleInputs struct {
3232
Cdc codec.Codec
3333
Environment appmodule.Environment
3434
AddressCodec address.Codec
35-
AccountKeeper types.AccountKeeper
35+
AuthKeeper types.AuthKeeper
3636
}
3737

3838
type ModuleOutputs struct {
@@ -54,7 +54,7 @@ func ProvideModule(in ModuleInputs) ModuleOutputs {
5454
}
5555
}
5656

57-
k := keeper.NewKeeper(authority, in.AddressCodec, in.Environment, in.Cdc, in.AccountKeeper)
57+
k := keeper.NewKeeper(authority, in.AddressCodec, in.Environment, in.Cdc, in.AuthKeeper)
5858
m := NewAppModule(in.Cdc, k)
5959

6060
return ModuleOutputs{

x/bank/v2/keeper/keeper.go

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ import (
2424
type Keeper struct {
2525
appmodulev2.Environment
2626

27-
ak types.AccountKeeper
27+
ak types.AuthKeeper
2828
authority []byte
2929
addressCodec address.Codec
3030
schema collections.Schema
@@ -33,7 +33,7 @@ type Keeper struct {
3333
supply collections.Map[string, math.Int]
3434
}
3535

36-
func NewKeeper(authority []byte, addressCodec address.Codec, env appmodulev2.Environment, cdc codec.BinaryCodec, ak types.AccountKeeper) *Keeper {
36+
func NewKeeper(authority []byte, addressCodec address.Codec, env appmodulev2.Environment, cdc codec.BinaryCodec, ak types.AuthKeeper) *Keeper {
3737
sb := collections.NewSchemaBuilder(env.KVStoreService)
3838

3939
k := &Keeper{
@@ -58,7 +58,7 @@ func NewKeeper(authority []byte, addressCodec address.Codec, env appmodulev2.Env
5858
// MintCoins creates new coins from thin air and adds it to the module account.
5959
// An error is returned if the module account does not exist or is unauthorized.
6060
func (k Keeper) MintCoins(ctx context.Context, moduleName string, amounts sdk.Coins) error {
61-
61+
6262
// TODO: Mint restriction
6363
acc := k.ak.GetModuleAccount(ctx, moduleName)
6464
if acc == nil {
@@ -129,7 +129,7 @@ func (k Keeper) SendCoins(ctx context.Context, from, to string, amt sdk.Coins) e
129129
return fmt.Errorf("%s is not an address or module name", to)
130130
}
131131
}
132-
132+
133133
// TODO: Send restriction
134134

135135
err = k.subUnlockedCoins(ctx, fromAddr, amt)

x/bank/v2/types/expected_keepers.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,9 @@ import (
66
sdk "github.com/cosmos/cosmos-sdk/types"
77
)
88

9-
// AccountKeeper defines the account contract that must be fulfilled when
9+
// AuthKeeper defines the account contract that must be fulfilled when
1010
// creating a x/bank keeper.
11-
type AccountKeeper interface {
11+
type AuthKeeper interface {
1212
GetAccount(ctx context.Context, addr sdk.AccAddress) sdk.AccountI
1313
GetModuleAccount(ctx context.Context, moduleName string) sdk.ModuleAccountI
1414
GetModuleAddress(moduleName string) sdk.AccAddress

0 commit comments

Comments
 (0)