fix: narrow diagnostic session tail

This commit is contained in:
Peter Steinberger
2026-05-04 05:47:03 +01:00
parent 117364e2b9
commit 1360cec546

View File

@@ -106,7 +106,7 @@ export function readLastAssistantFromSessionFile(filePath: string | undefined):
return undefined;
}
const tail = readTailText(filePath);
if (!tail.text) {
if (!tail?.text) {
return undefined;
}
const lines = tail.text.split(/\r?\n/).filter(Boolean);