Skip to content

Commit 34c058f

Browse files
committed
fix(workflows): adjust loop steps count and target index calculation
Update bmad-review loop steps from 2 to 3 and fix target index calculation in post step directives
1 parent 21de2be commit 34c058f

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

src/workflows/step/hooks.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -217,10 +217,10 @@ export async function processPostStepDirectives(context: ProcessPostStepContext)
217217
if (postResult.newActiveLoop !== undefined) {
218218
ctx.setActiveLoop(postResult.newActiveLoop);
219219
}
220-
// Return target index (add 1 because newIndex is 0-based target - 1)
220+
// Return target index as-is (INPUT_RECEIVED will increment by 1)
221221
return {
222222
type: 'loop',
223-
targetIndex: postResult.newIndex + 1,
223+
targetIndex: postResult.newIndex,
224224
newActiveLoop: postResult.newActiveLoop ?? null,
225225
};
226226
}

templates/workflows/bmad.workflow.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,6 @@ export default {
3838
separator("⟲ Story Loop ⟲"),
3939
resolveStep('bmad-stories', {interactive: false}),
4040
resolveStep('bmad-dev', {interactive: false}),
41-
resolveModule('bmad-review', {interactive: false, loopSteps: 2 }),
41+
resolveModule('bmad-review', {interactive: false, loopSteps: 3 }),
4242
],
4343
};

0 commit comments

Comments
 (0)