use misbehavior instead of misbehaviors to avoid breaking the api

This commit is contained in:
Callum Waters
2022-11-16 15:47:10 +01:00
parent d0b8b8a358
commit a9ff8da368
7 changed files with 246 additions and 247 deletions
+1 -1
View File
@@ -196,7 +196,7 @@ func (app *Application) FinalizeBlock(_ context.Context, req *types.RequestFinal
app.stagedTxs = make([][]byte, 0)
// Punish validators who committed equivocation.
for _, ev := range req.Misbehaviors {
for _, ev := range req.Misbehavior {
if ev.Type == types.MisbehaviorType_DUPLICATE_VOTE {
addr := string(ev.Validator.Address)
if pubKey, ok := app.valAddrToPubKeyMap[addr]; ok {