|
|
@@ -75,8 +75,6 @@ export const useSessionCommands = (actions: SessionCommandContext) => {
|
|
|
import.meta.env.VITE_OPENCODE_CHANNEL !== "beta" ||
|
|
|
settings.general.showFileTree()
|
|
|
|
|
|
- const idle = { type: "idle" as const }
|
|
|
- const status = () => sync.data.session_status[params.id ?? ""] ?? idle
|
|
|
const messages = () => {
|
|
|
const id = params.id
|
|
|
if (!id) return []
|
|
|
@@ -290,7 +288,7 @@ export const useSessionCommands = (actions: SessionCommandContext) => {
|
|
|
const sessionID = params.id
|
|
|
if (!sessionID) return
|
|
|
|
|
|
- if (status().type !== "idle") {
|
|
|
+ if (sync.data.session_working(params.id ?? "")) {
|
|
|
await sdk.client.session.abort({ sessionID }).catch(() => {})
|
|
|
}
|
|
|
|