pool using time and end block handler staking
This commit is contained in:
@@ -5,6 +5,7 @@ import (
|
||||
|
||||
sdk "github.com/cosmos/cosmos-sdk/types"
|
||||
"github.com/cosmos/cosmos-sdk/x/bank"
|
||||
abci "github.com/tendermint/abci/types"
|
||||
)
|
||||
|
||||
//nolint
|
||||
@@ -35,6 +36,17 @@ func NewHandler(k Keeper, ck bank.CoinKeeper) sdk.Handler {
|
||||
}
|
||||
}
|
||||
|
||||
//_______________________________________________
|
||||
|
||||
// NewEndBlocker generates sdk.EndBlocker
|
||||
// Performs tick functionality
|
||||
func NewEndBlocker(k Keeper) sdk.EndBlocker {
|
||||
return func(ctx sdk.Context, req abci.RequestEndBlock) (res abci.ResponseEndBlock) {
|
||||
res.ValidatorUpdates = k.Tick(ctx)
|
||||
return
|
||||
}
|
||||
}
|
||||
|
||||
//_____________________________________________________________________
|
||||
|
||||
// These functions assume everything has been authenticated,
|
||||
|
||||
Reference in New Issue
Block a user