From ccb2b4abd2ab551d98aa84dc388d8c286abe6380 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tuomas=20M=C3=A4kinen?= <1947505+tuommaki@users.noreply.github.com> Date: Mon, 18 Mar 2024 21:06:28 +0200 Subject: [PATCH] Fix workflow steps indexing condition (#149) --- crates/node/src/workflow/mod.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/crates/node/src/workflow/mod.rs b/crates/node/src/workflow/mod.rs index c32926c4..58339ae1 100644 --- a/crates/node/src/workflow/mod.rs +++ b/crates/node/src/workflow/mod.rs @@ -82,7 +82,7 @@ impl WorkflowEngine { match workflow.steps.iter().position(|s| s.program == *prover) { Some(proof_step_idx) => { - if workflow.steps.len() <= proof_step_idx { + if workflow.steps.len() <= (proof_step_idx + 1) { Err(WorkflowError::WorkflowStepMissing(format!( "verifier for proof tx {}", cur_tx.hash.clone(),