-
Notifications
You must be signed in to change notification settings - Fork 5
Open
Labels
Description
Faulty codemod
Sample code snippets
Original
const templates = useMemo(() => {
return templatesData.filter((template) =>
isValidExtension(template.file_extension),
);
}, [templatesData]);Expected
const templates = templatesData.filter((template) =>
isValidExtension(template.file_extension),
);Actual
const templates = () => {
return templatesData.filter((template) =>
isValidExtension(template.file_extension),
);
};Estimated impact
-/-
Logs:
-/-
Additional context
I think that a rewrite of this rule can be quite complicated, so it might be better not to raise false expectations and remove it. Having it in as is at least is bad, because it generates code that has a different type as it has had before.
In case there's anything more you need, please answer to this issue. I just wanted to provide you with as minimal out-of-context info as possible.