mirror of
https://github.com/LazyVim/LazyVim.git
synced 2025-07-01 04:54:35 +02:00
fix(nvim-lint): dont evaluate conditions for linter functions. Fixes #1569
This commit is contained in:
parent
63467c1f21
commit
b1ad48067e
1 changed files with 1 additions and 1 deletions
|
@ -49,7 +49,7 @@ return {
|
||||||
ctx.dirname = vim.fn.fnamemodify(ctx.filename, ":h")
|
ctx.dirname = vim.fn.fnamemodify(ctx.filename, ":h")
|
||||||
names = vim.tbl_filter(function(name)
|
names = vim.tbl_filter(function(name)
|
||||||
local linter = lint.linters[name]
|
local linter = lint.linters[name]
|
||||||
return linter and not (linter.condition and not linter.condition(ctx))
|
return linter and not (type(linter) == "table" and linter.condition and not linter.condition(ctx))
|
||||||
end, names)
|
end, names)
|
||||||
|
|
||||||
if #names > 0 then
|
if #names > 0 then
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue