From 4e1064266f4d4fc2b4aaade7661c28dc56dc1574 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=8E=8B=E5=BE=B7=E5=AE=87?= Date: Thu, 10 Sep 2026 19:05:48 +0800 Subject: [PATCH] =?UTF-8?q?=E7=A7=BB=E9=99=A4=E8=87=AA=E5=8A=A8=E5=88=87?= =?UTF-8?q?=E5=88=86=E7=BB=93=E6=9E=9C=E7=9A=84=E5=86=97=E4=BD=99=E7=B1=BB?= =?UTF-8?q?=E5=9E=8B=E6=96=AD=E8=A8=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 依赖空值检查后的 TypeScript 类型收窄直接使用 SeparationDTO。 不改变自动切分流程或运行时行为。 --- .../ai-game-creator-shell/src/view/ui-editor/useUiEditorPage.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/apps/ai-game-creator-shell/src/view/ui-editor/useUiEditorPage.ts b/apps/ai-game-creator-shell/src/view/ui-editor/useUiEditorPage.ts index 735a02af7..39726526d 100644 --- a/apps/ai-game-creator-shell/src/view/ui-editor/useUiEditorPage.ts +++ b/apps/ai-game-creator-shell/src/view/ui-editor/useUiEditorPage.ts @@ -1185,7 +1185,7 @@ export function useUiEditorSession( })); if (separationResult === null) throw new Error('自动切分素材没有返回结果'); - const completedResult = separationResult as SeparationDTO; + const completedResult = separationResult; if (!(await save())) { throw new Error( '自动切分素材结果已写入编辑器,但 State 保存失败;sidecar 已保留,可继续恢复。',