diff --git a/lua/telescope/builtin/__diagnostics.lua b/lua/telescope/builtin/__diagnostics.lua index e29be31573..0940827e6a 100644 --- a/lua/telescope/builtin/__diagnostics.lua +++ b/lua/telescope/builtin/__diagnostics.lua @@ -87,6 +87,9 @@ local diagnostics_to_tbl = function(opts) diagnosis_opts.severity["max"] = opts.severity_bound end end + if vim.version().minor > 9 and vim.tbl_isempty(diagnosis_opts.severity) then + diagnosis_opts.severity = nil + end opts.root_dir = opts.root_dir == true and vim.loop.cwd() or opts.root_dir