From 02bc88e6d61bd10272277796ca8ea3ad96a388dd Mon Sep 17 00:00:00 2001 From: TheLeoP <53507599+TheLeoP@users.noreply.github.com> Date: Sun, 19 Sep 2021 10:38:44 -0500 Subject: [PATCH] fix: pickers use entry.filename as default and fallback to entry.value for file_ignore_patterns (#1243) --- lua/telescope/pickers.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lua/telescope/pickers.lua b/lua/telescope/pickers.lua index 624ab00..09a062f 100644 --- a/lua/telescope/pickers.lua +++ b/lua/telescope/pickers.lua @@ -1049,7 +1049,7 @@ function Picker:get_result_processor(find_id, prompt, status_updater) -- a ton of time on large results. log.trace("Processing result... ", entry) for _, v in ipairs(self.file_ignore_patterns or {}) do - local file = type(entry.value) == "string" and entry.value or entry.filename + local file = vim.F.if_nil(entry.filename, type(entry.value) == "string" and entry.value) -- false if none is true if file then if string.find(file, v) then log.trace("SKIPPING", entry.value, "because", v)