Skip to content

fn_transform filtering is broken #2185

@ibhagwan

Description

@ibhagwan

One thing I noticed when experimenting with multiprocess=false, if fn_transform returns nil, sometimes other items returned by fn_transform won't render. I'm able to reproduce with this:

-- renders nothing
fzf_lua.fzf_exec("echo 'one\ntwo\nthree\nfour\n'", {
  fn_transform = function(item)
    if item == "three" then
      return
    end
    return item
  end,
})

-- renders one, two, three as expected
fzf_lua.fzf_exec("echo 'one\ntwo\nthree\nfour\n'", {
  fn_transform = function(item)
    if item == "four" then
      return
    end
    return item
  end,
})

Is that intentional, is there a new way to filter out items?

Originally posted by @elanmed in #2174 (reply in thread)

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions