diff --git a/src/abstractWrappers/Disputes.js b/src/abstractWrappers/Disputes.js index e3805c9..7ca8649 100644 --- a/src/abstractWrappers/Disputes.js +++ b/src/abstractWrappers/Disputes.js @@ -728,11 +728,12 @@ class Disputes extends AbstractWrapper { const baseFee = dispute.arbitrationFeePerJuror const draws = appealDraws[appeal] || [] let canRule = false - if (appeal === lastSession && draws.length > 0) { + if (firstSession + appeal === lastSession && draws.length > 0) { canRule = await this._Arbitrator.canRuleDispute( - account, + arbitratorAddress, disputeId, - draws + draws, + account ) } diff --git a/tests/kleros.test.js b/tests/kleros.test.js index aa6dca7..7cf6fd0 100644 --- a/tests/kleros.test.js +++ b/tests/kleros.test.js @@ -673,6 +673,7 @@ describe('Kleros', () => { expect(disputeForJuror.arbitrableContractAddress).toEqual( contractArbitrableTransactionData.address ) + expect(disputeForJuror.appealJuror[0].canRule).toBeTruthy() const jurorForNotifications = drawA.length > drawB.length ? juror1 : juror2