Skip to content

Commit b4daf68

Browse files
committed
Make sure nvim_get_autocmds never gets nil id
1 parent 1bd282f commit b4daf68

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lua/neocodeium/init.lua

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -132,7 +132,7 @@ local function enable_autocmds()
132132

133133
create_autocmd({ "WinEnter", "BufEnter" }, {
134134
callback = function()
135-
if not nvim_get_autocmds({ id = mode_changed_id })[1] then
135+
if not nvim_get_autocmds({ id = (mode_changed_id or -2) })[1] then
136136
insert_enter_once()
137137
end
138138
end,

0 commit comments

Comments
 (0)