Skip to content

Commit

Permalink
fix: make sure to apply if has diff
Browse files Browse the repository at this point in the history
Signed-off-by: Aaron Pham <[email protected]>
  • Loading branch information
aarnphm committed Aug 16, 2024
1 parent 6427a7e commit c612921
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lua/avante/ai_bot.lua
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@ local function call_claude_api_stream(question, code_lang, code_content, on_chun

local url = utils.trim_suffix(config.get().claude.endpoint, "/") .. "/v1/messages"

print("Sending request to Claude API...")
-- print("Sending request to Claude API...")

curl.post(url, {
---@diagnostic disable-next-line: unused-local
Expand Down Expand Up @@ -210,7 +210,7 @@ local function call_openai_api_stream(question, code_lang, code_content, on_chun
}
end

print("Sending request to " .. (config.get().provider == "azure" and "Azure OpenAI" or "OpenAI") .. " API...")
-- print("Sending request to " .. (config.get().provider == "azure" and "Azure OpenAI" or "OpenAI") .. " API...")

curl.post(url, {
---@diagnostic disable-next-line: unused-local
Expand Down
2 changes: 2 additions & 0 deletions lua/avante/sidebar.lua
Original file line number Diff line number Diff line change
Expand Up @@ -582,6 +582,8 @@ function Sidebar:render()
-- Save chat history
table.insert(chat_history or {}, { timestamp = timestamp, requirement = user_input, response = full_response })
save_chat_history(self, chat_history)

apply()
end)
end

Expand Down

0 comments on commit c612921

Please sign in to comment.