`no-array-callback-reference` false positive
Pnlvfx opened this issue · comments
Simone Gauli commented
As you can see down here, I'm getting the error: Do not pass a function. However I'm not passing a function, the variable "s" is a string a not a function,
the containerElement_.find is a cheerio function that accept a string, so nothing is wrong on my code.
const sel = ["a[href^='/imgres']", 'a[jsaction]'];
const linkElementHref = sel.map((s) => containerElement_.find(s)
Do not pass function `s` directly to `.find(…)`.eslint[unicorn/no-array-callback-reference](https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v51.0.1/docs/rules/no-array-callback-reference.md)
Federico Brigante commented
Duplicate of #1193