Commit 763fda7f authored by Adrian Sutton's avatar Adrian Sutton Committed by GitHub

op-dispute-mon: Collateral is only required for claims that are NOT resolved (#9970)

parent bb42eb30
......@@ -38,7 +38,7 @@ func CalculateRequiredCollateral(games []*monTypes.EnrichedGameData) map[common.
func requiredCollateralForGame(game *monTypes.EnrichedGameData) *big.Int {
required := big.NewInt(0)
for _, claim := range game.Claims {
if claim.Resolved {
if !claim.Resolved {
required = new(big.Int).Add(required, claim.Bond)
}
}
......
......@@ -101,7 +101,6 @@ func TestCalculateRequiredCollateral(t *testing.T) {
Claimant: common.Address{0x03},
CounteredBy: common.Address{},
},
Resolved: true,
},
},
Credits: map[common.Address]*big.Int{
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment