fix: accept null groupby in form data for timeseries table viz (#13086)

* Allowing timeseries table groupby to be null in form data

* Check truthiness for is_group_by

Co-authored-by: michelle_thomas <michelle.thomas@airbnb.com>
This commit is contained in:
michellethomas
2021-02-17 13:45:39 -08:00
committed by GitHub
parent 4c544500a7
commit 91db008d72
2 changed files with 2 additions and 2 deletions

View File

@@ -20,7 +20,7 @@ export default function transformProps(chartProps) {
const { height, datasource, formData, queriesData } = chartProps;
const { columnCollection = [], groupby, metrics, url } = formData;
const { records, columns } = queriesData[0].data;
const isGroupBy = groupby.length > 0;
const isGroupBy = groupby?.length > 0;
// When there is a "group by",
// each row in the table is a database column