Skip to content

Commit

Permalink
fix(mappings): adapt to renaming to api
Browse files Browse the repository at this point in the history
  • Loading branch information
max397574 committed Jun 27, 2024
1 parent 3c607e1 commit f31a3d6
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions lua/neocomplete/mappings.lua
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ end

local function map(plug, callback)
vim.keymap.set("i", plug, function()
if require("neocomplete").mappings.is_open() then
if require("neocomplete").api.is_open() then
callback()
else
mappings.get_fallback(get_mapping(plug))()
Expand All @@ -30,19 +30,19 @@ end

function mappings.setup()
map("<Plug>(NeocompleteConfirm)", function()
require("neocomplete").mappings.confirm()
require("neocomplete").api.confirm()
end)

map("<Plug>(NeocompleteSelectNext)", function()
require("neocomplete").mappings.select_next(1)
require("neocomplete").api.select_next(1)
end)

map("<Plug>(NeocompleteSelectPrev)", function()
require("neocomplete").mappings.select_prev(1)
require("neocomplete").api.select_prev(1)
end)

map("<Plug>(NeocompleteClose)", function()
require("neocomplete").mappings.close()
require("neocomplete").api.close()
end)
end

Expand Down

0 comments on commit f31a3d6

Please sign in to comment.