fixes error with postFlightRequest (#16643) (#16887)

This commit is contained in:
Peter Pisljar 2018-02-23 12:32:44 +01:00 committed by GitHub
parent 030b5ba577
commit afa91e20df
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -51,7 +51,7 @@ const CourierRequestHandlerProvider = function (Private, courier, timefilter) {
return _.cloneDeep(resp);
}).then(async resp => {
for (const agg of vis.aggs) {
for (const agg of vis.getAggConfig()) {
const nestedSearchSource = new SearchSource().inherits(searchSource);
resp = await agg.type.postFlightRequest(resp, vis.aggs, agg, nestedSearchSource);
}