Skip to content

Commit

Permalink
fix: use correct non-nil variables (closes #568) (#587)
Browse files Browse the repository at this point in the history
  • Loading branch information
anthonyokc authored Sep 15, 2024
1 parent de9f36f commit dadf0dc
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions lua/avante/init.lua
Original file line number Diff line number Diff line change
Expand Up @@ -167,7 +167,7 @@ H.keymaps = function()
)
end

if Config.behaviour.auto_suggestion then
if Config.behaviour.auto_suggestions then
Utils.safe_keymap_set("i", Config.mappings.suggestion.accept, function()
local _, _, sg = M.get()
sg:accept()
Expand Down Expand Up @@ -371,9 +371,9 @@ M.toggle.hint = H.api(Utils.toggle_wrap({

M.toggle.suggestion = H.api(Utils.toggle_wrap({
name = "suggestion",
get = function() return Config.behaviour.auto_suggestion end,
get = function() return Config.behaviour.auto_suggestions end,
set = function(state)
Config.override({ behaviour = { auto_suggestion = state } })
Config.override({ behaviour = { auto_suggestions = state } })
local _, _, sg = M.get()
if state ~= false then
if sg then sg:setup_autocmds() end
Expand Down

0 comments on commit dadf0dc

Please sign in to comment.