Skip to content

Commit 5e2dd7e

Browse files
committed
fix: avoid workboard board id shadowing
1 parent d608113 commit 5e2dd7e

1 file changed

Lines changed: 4 additions & 4 deletions

File tree

extensions/workboard/src/store.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4186,14 +4186,14 @@ export class WorkboardStore {
41864186
latest = await this.recordDispatch(latest, now);
41874187
}
41884188
if (await this.shouldAutoOrchestrate(latest)) {
4189-
const boardId = cardBoardId(latest);
4190-
const board = await this.boardStore.lookup(boardId);
4189+
const latestBoardId = cardBoardId(latest);
4190+
const board = await this.boardStore.lookup(latestBoardId);
41914191
const cap = board?.board.orchestration?.autoDecomposePerDispatch ?? 3;
4192-
const boardCount = orchestratedByBoard.get(boardId) ?? 0;
4192+
const boardCount = orchestratedByBoard.get(latestBoardId) ?? 0;
41934193
if (boardCount < cap) {
41944194
latest = await this.recordOrchestrationCandidate(latest, now);
41954195
orchestrated.push(latest);
4196-
orchestratedByBoard.set(boardId, boardCount + 1);
4196+
orchestratedByBoard.set(latestBoardId, boardCount + 1);
41974197
}
41984198
}
41994199
if (wasPromoted && latest.status !== "blocked") {

0 commit comments

Comments
 (0)