Skip to content

Commit

Permalink
fix: disable create/edit validator
Browse files Browse the repository at this point in the history
  • Loading branch information
forcodedancing committed Apr 7, 2024
1 parent cf3ab19 commit bd19c60
Showing 1 changed file with 20 additions and 16 deletions.
36 changes: 20 additions & 16 deletions x/stake/handler.go
Original file line number Diff line number Diff line change
Expand Up @@ -43,25 +43,29 @@ func NewHandler(k keeper.Keeper, govKeeper gov.Keeper) sdk.Handler {
return handleMsgUndelegate(ctx, msg, k)
// case MsgSideChain
case types.MsgCreateSideChainValidator:
if sdk.IsUpgrade(sdk.FirstSunsetFork) {
return sdk.ErrMsgNotSupported("").Result()
}
return handleMsgCreateSideChainValidator(ctx, msg, k)
return sdk.ErrMsgNotSupported("Temporarily unavailable").Result()
//if sdk.IsUpgrade(sdk.FirstSunsetFork) {
// return sdk.ErrMsgNotSupported("").Result()
//}
//return handleMsgCreateSideChainValidator(ctx, msg, k)
case types.MsgEditSideChainValidator:
if sdk.IsUpgrade(sdk.FirstSunsetFork) {
return sdk.ErrMsgNotSupported("").Result()
}
return handleMsgEditSideChainValidator(ctx, msg, k)
return sdk.ErrMsgNotSupported("Temporarily unavailable").Result()
//if sdk.IsUpgrade(sdk.FirstSunsetFork) {
// return sdk.ErrMsgNotSupported("").Result()
//}
//return handleMsgEditSideChainValidator(ctx, msg, k)
case types.MsgCreateSideChainValidatorWithVoteAddr:
if sdk.IsUpgrade(sdk.FirstSunsetFork) {
return sdk.ErrMsgNotSupported("").Result()
}
return handleMsgCreateSideChainValidatorWithVoteAddr(ctx, msg, k)
return sdk.ErrMsgNotSupported("Temporarily unavailable").Result()
//if sdk.IsUpgrade(sdk.FirstSunsetFork) {
// return sdk.ErrMsgNotSupported("").Result()
//}
//return handleMsgCreateSideChainValidatorWithVoteAddr(ctx, msg, k)
case types.MsgEditSideChainValidatorWithVoteAddr:
if sdk.IsUpgrade(sdk.FirstSunsetFork) {
return sdk.ErrMsgNotSupported("").Result()
}
return handleMsgEditSideChainValidatorWithVoteAddr(ctx, msg, k)
return sdk.ErrMsgNotSupported("Temporarily unavailable").Result()
//if sdk.IsUpgrade(sdk.FirstSunsetFork) {
// return sdk.ErrMsgNotSupported("").Result()
//}
//return handleMsgEditSideChainValidatorWithVoteAddr(ctx, msg, k)
case types.MsgSideChainDelegate:
if sdk.IsUpgrade(sdk.FirstSunsetFork) {
return sdk.ErrMsgNotSupported("").Result()
Expand Down

0 comments on commit bd19c60

Please sign in to comment.