fix: tool result message must be adjacent to the tool use message (#2096)

This commit is contained in:
yetone
2025-05-29 03:55:32 +08:00
committed by GitHub
parent 7fd6cf3d64
commit d44db10535
3 changed files with 21 additions and 75 deletions

View File

@@ -65,7 +65,7 @@ function M.func(opts, on_log, on_complete, session_ctx)
just_for_display = true,
})
sidebar:add_history_messages({ message })
if opts.command then
if opts.command and opts.command ~= "" and opts.command ~= vim.NIL then
require("avante.llm_tools.bash").func({ command = opts.command }, on_log, on_complete, session_ctx)
else
on_complete(true, nil)