Skip to content

Commit

Permalink
Fixing issue with table viz for table with no metrics (apache#5205)
Browse files Browse the repository at this point in the history
  • Loading branch information
michellethomas authored and Grace Guo committed Jun 15, 2018
1 parent 4b7a14d commit b60ac5f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion superset/assets/src/visualizations/table.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ function tableVis(slice, payload) {
const data = payload.data;
const fd = slice.formData;

let metrics = fd.metrics.map(m => m.label || m);
let metrics = (fd.metrics || []).map(m => m.label || m);
// Add percent metrics
metrics = metrics.concat((fd.percent_metrics || []).map(m => '%' + m));
// Removing metrics (aggregates) that are strings
Expand Down

0 comments on commit b60ac5f

Please sign in to comment.