mirror of https://github.com/folke/lazy.nvim.git
fix(health): don't show warning on `module=false`
This commit is contained in:
parent
b68f94b95a
commit
c228908ffc
|
@ -100,6 +100,7 @@ require("lazy").setup({
|
|||
| **cmd** | `string?` or `string[]` | Lazy-load on command |
|
||||
| **ft** | `string?` or `string[]` | Lazy-load on filetype |
|
||||
| **keys** | `string?` or `string[]` | Lazy-load on key mapping |
|
||||
| **module** | `false?` | Do not automatically load this lua module when it's required somewhere |
|
||||
|
||||
### Lazy Loading
|
||||
|
||||
|
|
|
@ -37,6 +37,7 @@ function M.check()
|
|||
"tag",
|
||||
"commit",
|
||||
"version",
|
||||
"module",
|
||||
"pin",
|
||||
"cmd",
|
||||
"event",
|
||||
|
@ -48,7 +49,9 @@ function M.check()
|
|||
for _, plugin in pairs(Config.plugins) do
|
||||
for key in pairs(plugin) do
|
||||
if not vim.tbl_contains(valid, key) then
|
||||
vim.health.report_warn("{" .. plugin.name .. "}: unknown key <" .. key .. ">")
|
||||
if key ~= "module" or type(plugin.module) ~= "boolean" then
|
||||
vim.health.report_warn("{" .. plugin.name .. "}: unknown key <" .. key .. ">")
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Reference in New Issue