From e8ef88bfcbabde42b7a29e938dc5ebbdbb8b1c5f Mon Sep 17 00:00:00 2001 From: Simon Hauser Date: Sun, 9 Jan 2022 19:03:53 +0100 Subject: [PATCH] fix(builtin.treesitter): make sure that kind is not nil If kind is nil then prefilter throws an error fix #1631 --- lua/telescope/builtin/files.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lua/telescope/builtin/files.lua b/lua/telescope/builtin/files.lua index c247ffc..d71cf65 100644 --- a/lua/telescope/builtin/files.lua +++ b/lua/telescope/builtin/files.lua @@ -252,7 +252,7 @@ local function prepare_match(entry, kind) local entries = {} if entry.node then - entry["kind"] = kind + entry["kind"] = vim.F.if_nil(kind, "") table.insert(entries, entry) else for name, item in pairs(entry) do