[Intl] make type-hinted arguments nullable
This commit is contained in:
parent
34c8a8b7ae
commit
16ebeb395f
@ -132,7 +132,7 @@ class IntlDateFormatter
|
||||
* @throws MethodArgumentValueNotImplementedException When $locale different than "en" or null is passed
|
||||
* @throws MethodArgumentValueNotImplementedException When $calendar different than GREGORIAN is passed
|
||||
*/
|
||||
public function __construct(?string $locale, int $datetype, int $timetype, $timezone = null, ?int $calendar = self::GREGORIAN, string $pattern = null)
|
||||
public function __construct(?string $locale, ?int $datetype, ?int $timetype, $timezone = null, ?int $calendar = self::GREGORIAN, string $pattern = null)
|
||||
{
|
||||
if ('en' !== $locale && null !== $locale) {
|
||||
throw new MethodArgumentValueNotImplementedException(__METHOD__, 'locale', $locale, 'Only the locale "en" is supported');
|
||||
|
Reference in New Issue
Block a user