From 7c02bcbf09fd30240b3a06c92862ed94c65d413f Mon Sep 17 00:00:00 2001 From: mtsalenc Date: Wed, 13 May 2020 22:40:29 -0300 Subject: [PATCH] fix: disputed request should not return but continue --- .env.example | 2 +- src/index.ts | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.env.example b/.env.example index 37173da..4f607f9 100644 --- a/.env.example +++ b/.env.example @@ -14,7 +14,7 @@ BLOCK_TIME_SECONDS=4 # emitted by the factory. We can fetch logs more quickly by # sweeping the blockchain from the deployment block of the factory contract. # This field is optional, if not set, 0 will be used. -FACTORY_BLOCK_NUM=16384123 +FACTORY_BLOCK_NUM=18495615 # This is the account that will call execute unchallenged requests # and withdraw rewards for the users. diff --git a/src/index.ts b/src/index.ts index 47f2d76..4142782 100644 --- a/src/index.ts +++ b/src/index.ts @@ -176,7 +176,7 @@ const deploymentBlock = Number(process.env.FACTORY_BLOCK_NUM) || 0 console.info(` Checking ${pendingRequestCount} of ${pendingRequests.length}`) const { values: { _itemID, _requestIndex }} = pendingRequest const { submissionTime, disputed } = await tcr.getRequestInfo(_itemID, _requestIndex) - if (disputed) return // There is an ongoing dispute. No-op. + if (disputed) continue // There is an ongoing dispute. No-op. if (bigNumberify(timestamp).sub(submissionTime).gt(challengePeriodDuration)) { // Challenge period passed with no challenges, execute it.