diff --git a/contao/modules/ModuleRecommendation.php b/contao/modules/ModuleRecommendation.php index f0d50ec..c58ad0f 100644 --- a/contao/modules/ModuleRecommendation.php +++ b/contao/modules/ModuleRecommendation.php @@ -308,7 +308,7 @@ protected function addInternalImage($objModel, &$objTemplate): void */ protected function getElapsedTime(string $strDateTime): string { - $objElapsedTime = (new \DateTime($strDateTime))->diff(new \DateTime()); + $objElapsedTime = (new \DateTime($strDateTime))->diff(new \DateTime(date("Y-m-d\TH:i:sP",time()))); if (($years = $objElapsedTime->y) > 0) {