Skip to content

Commit

Permalink
refactor code
Browse files Browse the repository at this point in the history
  • Loading branch information
Dreamer committed Jul 3, 2023
1 parent 56deb97 commit 3ec8f3e
Show file tree
Hide file tree
Showing 4 changed files with 16 additions and 18 deletions.
8 changes: 8 additions & 0 deletions modules/coinswap/depinject.go
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,14 @@ func ProvideKeyTable() exported.KeyTable {
return types.ParamKeyTable() //nolint:staticcheck
}

var _ appmodule.AppModule = AppModule{}

// IsOnePerModuleType implements the depinject.OnePerModuleType interface.
func (am AppModule) IsOnePerModuleType() {}

// IsAppModule implements the appmodule.AppModule interface.
func (am AppModule) IsAppModule() {}

type CoinswapInputs struct {
depinject.In

Expand Down
9 changes: 0 additions & 9 deletions modules/coinswap/module.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@ import (
"encoding/json"
"fmt"

"cosmossdk.io/core/appmodule"
"github.com/grpc-ecosystem/grpc-gateway/runtime"
"github.com/spf13/cobra"

Expand Down Expand Up @@ -114,14 +113,6 @@ func NewAppModule(
}
}

var _ appmodule.AppModule = AppModule{}

// IsOnePerModuleType implements the depinject.OnePerModuleType interface.
func (am AppModule) IsOnePerModuleType() {}

// IsAppModule implements the appmodule.AppModule interface.
func (am AppModule) IsAppModule() {}

// Name returns the coinswap module's name.
func (AppModule) Name() string { return types.ModuleName }

Expand Down
8 changes: 8 additions & 0 deletions modules/farm/depinject.go
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,14 @@ func ProvideKeyTable() exported.KeyTable {
return types.ParamKeyTable() //nolint:staticcheck
}

var _ appmodule.AppModule = AppModule{}

// IsOnePerModuleType implements the depinject.OnePerModuleType interface.
func (am AppModule) IsOnePerModuleType() {}

// IsAppModule implements the appmodule.AppModule interface.
func (am AppModule) IsAppModule() {}

type FarmInputs struct {
depinject.In

Expand Down
9 changes: 0 additions & 9 deletions modules/farm/module.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@ import (
"encoding/json"
"fmt"

"cosmossdk.io/core/appmodule"
"github.com/gorilla/mux"
"github.com/grpc-ecosystem/grpc-gateway/runtime"
"github.com/spf13/cobra"
Expand Down Expand Up @@ -122,14 +121,6 @@ func NewAppModule(
}
}

var _ appmodule.AppModule = AppModule{}

// IsOnePerModuleType implements the depinject.OnePerModuleType interface.
func (am AppModule) IsOnePerModuleType() {}

// IsAppModule implements the appmodule.AppModule interface.
func (am AppModule) IsAppModule() {}

// Name returns the farm module's name.
func (AppModule) Name() string { return types.ModuleName }

Expand Down

0 comments on commit 3ec8f3e

Please sign in to comment.