Skip to content

Commit 6e4a661

Browse files
authored
BUG: Automatically pass self for server method calls (virtual_text) (#300)
* BUG: Automatically pass call to check server health (virtual_text) * BUG: Replace all instances of `.` with `:` (virtual_text)
1 parent ad44148 commit 6e4a661

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

lua/codeium/virtual_text.lua

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -171,7 +171,7 @@ local function completion_inserter(current_completion, insert_text)
171171

172172
local cursor_text = delta == 0 and "" or '<C-O>:exe "go" line2byte(line("."))+col(".")+(' .. delta .. ")<CR>"
173173

174-
server.accept_completion(current_completion.completion.completionId)
174+
server:accept_completion(current_completion.completion.completionId)
175175

176176
return '<C-g>u' .. delete_range .. insert_text .. cursor_text
177177
end
@@ -438,7 +438,7 @@ function M.complete(opts)
438438

439439
codeium_status = "waiting"
440440

441-
local cancel = server.request_completion(
441+
local cancel = server:request_completion(
442442
data.document,
443443
data.editor_options,
444444
data.other_documents,
@@ -484,7 +484,7 @@ end
484484

485485
function M.debounced_complete()
486486
M.clear()
487-
if config.options.virtual_text.manual or not server.is_healthy() or not M.filetype_enabled(vim.fn.bufnr("")) then
487+
if config.options.virtual_text.manual or not server:is_healthy() or not M.filetype_enabled(vim.fn.bufnr("")) then
488488
return
489489
end
490490
local current_buf = vim.fn.bufnr("")

0 commit comments

Comments
 (0)