mirror of
https://fastgit.cc/https://github.com/anomalyco/opencode
synced 2026-04-22 05:42:35 +08:00
fix: filter empty messages in toModelMessage (#4811)
This commit is contained in:
@@ -666,7 +666,7 @@ export namespace MessageV2 {
|
||||
}
|
||||
}
|
||||
|
||||
return convertToModelMessages(result)
|
||||
return convertToModelMessages(result.filter((msg) => msg.parts.length > 0))
|
||||
}
|
||||
|
||||
export const stream = fn(Identifier.schema("session"), async function* (sessionID) {
|
||||
|
||||
Reference in New Issue
Block a user