Skip to content

Commit 5ecf13c

Browse files
committed
Fix remaining deprecation warnings on nvim nightly
1 parent 7223b81 commit 5ecf13c

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

lua/jdtls/util.lua

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ function M.execute_command(command, callback, bufnr)
5353
end
5454
end
5555
end
56-
clients[1].request('workspace/executeCommand', command, callback, bufnr)
56+
clients[1]:request('workspace/executeCommand', command, callback, bufnr)
5757
if co then
5858
return coroutine.yield()
5959
end
@@ -65,9 +65,7 @@ end
6565
---@param fn fun(java_exec: string)
6666
---@param bufnr integer?
6767
function M.with_java_executable(mainclass, project, fn, bufnr)
68-
vim.validate({
69-
mainclass = { mainclass, 'string' }
70-
})
68+
assert(type(mainclass) == "string", "mainclass must be a string")
7169

7270
bufnr = assert((bufnr == nil or bufnr == 0) and api.nvim_get_current_buf() or bufnr)
7371

0 commit comments

Comments
 (0)