Skip to content

Commit cb079ef

Browse files
fix: handle unhandled promise rejection when aborting session
Fixes anomalyco#7851
1 parent a803cf8 commit cb079ef

1 file changed

Lines changed: 1 addition & 3 deletions

File tree

  • packages/opencode/src/cli/cmd/tui/component/prompt

‎packages/opencode/src/cli/cmd/tui/component/prompt/index.tsx‎

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -215,9 +215,7 @@ export function Prompt(props: PromptProps) {
215215
}, 5000)
216216

217217
if (store.interrupt >= 2) {
218-
sdk.client.session.abort({
219-
sessionID: props.sessionID,
220-
})
218+
sdk.client.session.abort({ sessionID: props.sessionID }).catch(() => {})
221219
setStore("interrupt", 0)
222220
}
223221
dialog.clear()

0 commit comments

Comments
 (0)