From 88867e80e57ac230f4f36f4f59211269d88538dc Mon Sep 17 00:00:00 2001 From: Momentry Studio Date: Fri, 23 Oct 2026 20:22:48 +0800 Subject: [PATCH] fix: handle 404 for scenes endpoint gracefully - Scenes endpoint may not be implemented in Core API yet - useVLMScenes returns empty array instead of error on 404 --- src/composables/useVLM.ts | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/composables/useVLM.ts b/src/composables/useVLM.ts index f0c57b2..4c6d86c 100644 --- a/src/composables/useVLM.ts +++ b/src/composables/useVLM.ts @@ -61,6 +61,11 @@ export function useVLMScenes(fileUuid: string) { try { const base = getApiBase() const resp = await fetch(`${base}/api/v1/file/${fileUuid}/scenes`) + if (resp.status === 404) { + // Scenes endpoint may not be implemented yet + scenes.value = [] + return + } if (!resp.ok) throw new Error(`HTTP ${resp.status}`) const data = await resp.json() scenes.value = Array.isArray(data) ? data : (data.scenes || [])