fix: tool_info is nil

This commit is contained in:
yetone
2025-07-21 11:50:14 +08:00
parent 0490927061
commit 75ebef9fbe
2 changed files with 3 additions and 0 deletions

View File

@@ -241,6 +241,7 @@ local function refresh_history(messages, tools, files, add_diagnostic, tools_to_
if use then
-- This is a tool invocation message. We will be handling both use and result together.
local tool_info = tools[use.id]
if not tool_info then goto continue end
if not tool_info.result then goto continue end
if tool_count < tools_to_text then