fix: throw error on vim.has call within the lsp/workspace.lua (#411)

This commit is contained in:
Nam Nguyen 2024-06-11 21:23:04 +10:00 committed by GitHub
parent e5eb20e88f
commit 61f1967222
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -77,7 +77,7 @@ local function get_matching_paths(client, filters, paths)
if vim.glob and vim.glob.to_lpeg then
-- HACK around https://github.com/neovim/neovim/issues/28931
-- find alternations and sort them by length to try to match the longest first
if vim.has("nvim-0.11") == 0 then
if vim.fn.has("nvim-0.11") == 0 then
glob = glob:gsub("{(.*)}", function(s)
local pieces = vim.split(s, ",")
table.sort(pieces, function(a, b)