Skip to content

Commit

Permalink
fix(testnetify): decrease bonded balance when validator drops from ac…
Browse files Browse the repository at this point in the history
…tive list

Signed-off-by: Artur Troian <[email protected]>
  • Loading branch information
troian committed May 5, 2023
1 parent 5d33944 commit dfeacae
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 4 deletions.
4 changes: 1 addition & 3 deletions cmd/akash/cmd/testnetify/state.go
Original file line number Diff line number Diff line change
Expand Up @@ -974,9 +974,7 @@ func (ga *GenesisState) ensureActiveSet(cdc codec.Codec) error {
Power: power,
})

}

if val.IsBonded() {
} else if val.IsBonded() {
sVals[i].Status = stakingtypes.Unbonding
coins := sdk.NewCoins(sdk.NewCoin("uakt", val.DelegatorShares.RoundInt()))
err := ga.DecreaseBalances(cdc, ga.moduleAddresses.bondedPool, coins)
Expand Down
2 changes: 1 addition & 1 deletion util/cli/configs.go
Original file line number Diff line number Diff line change
Expand Up @@ -130,7 +130,7 @@ func parseTimestampFormat(val string) (string, error) {
return time.Kitchen, nil
}

return "", fmt.Errorf("invalid timestamp format (%s)", val)
return "", fmt.Errorf("invalid timestamp format (%s)", val) // nolint: goerr113
}

func bindFlags(cmd *cobra.Command, v *viper.Viper, envPrefixes []string) error {
Expand Down

0 comments on commit dfeacae

Please sign in to comment.