The open source coding agent.
TypeScript
fix(session): ensure agent exists before processing title in session summary (#8662)
Qunhong Zengb14622352e54
diff --git a/packages/opencode/src/session/summary.ts b/packages/opencode/src/session/summary.tsindex 2bd1b0da601..dbca218f9c6 100644--- a/packages/opencode/src/session/summary.ts+++ b/packages/opencode/src/session/summary.ts@@ -77,6 +77,7 @@ export namespace SessionSummary {const textPart = msgWithParts.parts.find((p) => p.type === "text" && !p.synthetic) as MessageV2.TextPartif (textPart && !userMsg.summary?.title) {const agent = await Agent.get("title")+ if (!agent) returnconst stream = await LLM.stream({agent,user: userMsg,