ElasticsearchDSL icon indicating copy to clipboard operation
ElasticsearchDSL copied to clipboard

Allow null 'format' in DateRangeAggregation

Open pmishev opened this issue 4 years ago • 1 comments

Allow null 'format' in DateRangeAggregation

Without this, calling:

        $ranges[] = ['from' => time()-1000, 'to' => time(), 'key' => 'time_range'];
        $rangeAgg = new DateRangeAggregation('myagg', 'created', null, $ranges, true);

results in an exception, but it shouldn't as format is optional.

pmishev avatar Mar 11 '21 15:03 pmishev

Have you considered merging this fix?

pmishev avatar Jun 09 '22 16:06 pmishev