fix: pickers use entry.filename as default and fallback to entry.value for file_ignore_patterns (#1243)
This commit is contained in:
@@ -1049,7 +1049,7 @@ function Picker:get_result_processor(find_id, prompt, status_updater)
|
|||||||
-- a ton of time on large results.
|
-- a ton of time on large results.
|
||||||
log.trace("Processing result... ", entry)
|
log.trace("Processing result... ", entry)
|
||||||
for _, v in ipairs(self.file_ignore_patterns or {}) do
|
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 file then
|
||||||
if string.find(file, v) then
|
if string.find(file, v) then
|
||||||
log.trace("SKIPPING", entry.value, "because", v)
|
log.trace("SKIPPING", entry.value, "because", v)
|
||||||
|
|||||||
Reference in New Issue
Block a user