Commit 653d1654 authored by Vladimirrem's avatar Vladimirrem Committed by Joris Vercammen

Issue #3030970 by Vladimirrem: Incorrect relative Date Processor calculation

parent 6fcfd475
......@@ -157,7 +157,7 @@ class SearchApiDate extends QueryTypeRangeBase {
switch ($this->getGranularity()) {
case static::FACETAPI_DATE_YEAR:
$startDate = $dateTime::createFromFormat('Y-m-d\TH:i:s', $value . '-1T00:00:00');
$startDate = $dateTime::createFromFormat('Y-m-d\TH:i:s', $value . '-01T00:00:00');
$stopDate = clone $startDate;
$stopDate->add(new \DateInterval('P1Y'));
$stopDate->sub(new \DateInterval('PT1S'));
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment