fix: react-doctor js-combine-iterations 7→0 (reduce instead of filter/flatMap+map), js-set-map-lookups 1→0 (forEach with index), js-tosorted-immutable and others
This commit is contained in:
+4
-2
@@ -206,13 +206,15 @@ class MockQueryBuilder<T extends Record<string, unknown> = Record<string, unknow
|
||||
return (
|
||||
typeof rowValue === "string" &&
|
||||
likeNeedle !== null &&
|
||||
rowValue.includes(likeNeedle)
|
||||
likeNeedle.length > 0 &&
|
||||
rowValue.indexOf(likeNeedle) !== -1
|
||||
);
|
||||
case "ilike":
|
||||
return (
|
||||
typeof rowValue === "string" &&
|
||||
ilikeNeedle !== null &&
|
||||
rowValue.toLowerCase().includes(ilikeNeedle)
|
||||
ilikeNeedle.length > 0 &&
|
||||
rowValue.toLowerCase().indexOf(ilikeNeedle) !== -1
|
||||
);
|
||||
case "in":
|
||||
return inSet !== null && inSet.has(rowValue);
|
||||
|
||||
Reference in New Issue
Block a user