Skip to content

Commit

Permalink
fix(native filters): groupby filter issue (#21084)
Browse files Browse the repository at this point in the history
(cherry picked from commit d79b0bf)
  • Loading branch information
stevetracvc authored and eschutho committed Sep 14, 2022
1 parent c3e04d7 commit 05d7c3d
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ export default function PluginFilterGroupBy(props: PluginFilterGroupByProps) {
}, [JSON.stringify(defaultValue), multiSelect]);

const groupbys = ensureIsArray(formData.groupby).map(getColumnLabel);
const groupby = groupbys[0].length ? groupbys[0] : null;
const groupby = groupbys[0]?.length ? groupbys[0] : null;

const withData = groupby
? data.filter(row => groupby.includes(row.column_name as string))
Expand Down

0 comments on commit 05d7c3d

Please sign in to comment.