Skip to content

Commit 7de9622

Browse files
committed
ACP2E-4344: Error Invalid date when updating account information
1 parent 5cdea8e commit 7de9622

File tree

1 file changed

+4
-4
lines changed
  • app/code/Magento/Customer/Block/Widget

1 file changed

+4
-4
lines changed

app/code/Magento/Customer/Block/Widget/Dob.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -482,14 +482,14 @@ private function normalizedDobOutput(mixed $value): mixed
482482
$locale = $this->localeResolver->getLocale();
483483
$dateFormat = $this->getDateFormat();
484484
$dateTime = $this->_localeDate->date($value, $locale, false, false);
485-
486-
return $this->_localeDate->formatDateTime(
487-
$dateTime,
485+
$formatter = new \IntlDateFormatter(
486+
Resolver::DEFAULT_LOCALE,
488487
\IntlDateFormatter::NONE,
489488
\IntlDateFormatter::NONE,
490-
Resolver::DEFAULT_LOCALE,
489+
$dateTime->getTimezone(),
491490
null,
492491
$dateFormat
493492
);
493+
return $formatter->format($dateTime);
494494
}
495495
}

0 commit comments

Comments
 (0)