2
0
Эх сурвалжийг харах

fix(session): ensure agent exists before processing title in session summary (#8662)

Qunhong Zeng 1 сар өмнө
parent
commit
b14622352e

+ 1 - 0
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.TextPart
     if (textPart && !userMsg.summary?.title) {
       const agent = await Agent.get("title")
+      if (!agent) return
       const stream = await LLM.stream({
         agent,
         user: userMsg,