From 99145e6ab9c325eafd6cd6ac81c144816a85d7c9 Mon Sep 17 00:00:00 2001 From: Aleksandr Ivlev Date: Thu, 25 Jul 2024 17:54:47 +0300 Subject: [PATCH] Fixed problem with action state checking --- src/PLottery.ts | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/src/PLottery.ts b/src/PLottery.ts index a2835b9..635705e 100644 --- a/src/PLottery.ts +++ b/src/PLottery.ts @@ -194,7 +194,6 @@ export class PLottery extends SmartContract { let lastProcessedState = this.lastProcessedState.getAndRequireEquals(); let lastProcessedTicketId = this.lastProcessedTicketId.getAndRequireEquals(); - let actionState = this.account.actionState.getAndRequireEquals(); reduceProof.publicOutput.processedActionList.assertEquals( ActionList.emptyHash, @@ -208,10 +207,7 @@ export class PLottery extends SmartContract { ); // Check that actionState is equal to actionState on proof - actionState.assertEquals( - reduceProof.publicOutput.finalState, - 'Final state is not match contract actionState' - ); + this.account.actionState.requireEquals(reduceProof.publicOutput.finalState); // Check inital ticket id lastProcessedTicketId.assertEquals(