diff --git a/src/ui/public/agg_types/buckets/date_histogram.js b/src/ui/public/agg_types/buckets/date_histogram.js index 58d3f0eb144a8..03bf6aa3f9b05 100644 --- a/src/ui/public/agg_types/buckets/date_histogram.js +++ b/src/ui/public/agg_types/buckets/date_histogram.js @@ -41,7 +41,8 @@ export default function DateHistogramAggType(timefilter, config, Private) { makeLabel: function (agg) { const output = this.params.write(agg); const params = output.params; - return params.field + ' per ' + (output.metricScaleText || output.bucketInterval.description); + const field = params.field || _.get(agg, 'params.field.displayName', ''); + return field + ' per ' + (output.metricScaleText || output.bucketInterval.description); }, createFilter: createFilter, decorateAggConfig: function () {