fix(ui): destructure {item} from POST /api/queue response
All checks were successful
Build & Push Docker Image / test-and-build (push) Successful in 1m1s

submitUrl() was using the full {duplicate, item} response object
as the queue item, causing 'Cannot read properties of undefined
(reading length)' crash when rendering phases in RecipeSheet/
TimelineRow.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
This commit is contained in:
Giancarmine Salucci
2026-05-12 22:50:53 +02:00
parent 040ae17c12
commit 8d979a9305

View File

@@ -130,7 +130,7 @@
const err = await response.json();
throw new Error(err.message || 'Failed to enqueue URL');
}
const queueItem = await response.json();
const { item: queueItem } = await response.json();
// Item will arrive via SSE, but add immediately for UX
items = [queueItem, ...items];
screen = 'home';