Skip to content

Commit b7084b0

Browse files
Update date exception thrown
1 parent 5d05b72 commit b7084b0

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

date/date_c.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -184,7 +184,7 @@ class DateTimeImmutable implements DateTimeInterface
184184
* The <em>$timezone</em> parameter and the current timezone are ignored when the <em>$datetime</em> parameter either
185185
* is a UNIX timestamp (e.g. <em>@946684800</em>) or specifies a timezone (e.g. <em>2010-01-28T15:00:00+02:00</em>).
186186
* </p></blockquote>
187-
* @throws Exception Emits Exception in case of an error.
187+
* @throws DateException Emits Exception in case of an error.
188188
*/
189189
public function __construct(
190190
#[LanguageLevelTypeAware(['8.0' => 'string'], default: '')] $datetime = "now",
@@ -531,7 +531,7 @@ class DateTime implements DateTimeInterface
531531
* or specifies a timezone
532532
* (e.g. <em>2010-01-28T15:00:00+02:00</em>).
533533
* </p> <p></p></blockquote>
534-
* @throws Exception Emits Exception in case of an error.
534+
* @throws DateException Emits Exception in case of an error.
535535
*/
536536
public function __construct(
537537
#[LanguageLevelTypeAware(['8.0' => 'string'], default: '')] $datetime = 'now',
@@ -763,7 +763,7 @@ class DateTimeZone
763763
/**
764764
* @param string $timezone
765765
* @link https://php.net/manual/en/datetimezone.construct.php
766-
* @throws Exception Emits Exception in case of an error.
766+
* @throws DateException Emits Exception in case of an error.
767767
*/
768768
public function __construct(#[LanguageLevelTypeAware(['8.0' => 'string'], default: '')] $timezone) {}
769769

@@ -915,7 +915,7 @@ class DateInterval
915915

916916
/**
917917
* @param string $duration
918-
* @throws Exception when the $duration cannot be parsed as an interval.
918+
* @throws DateException when the $duration cannot be parsed as an interval.
919919
* @link https://php.net/manual/en/dateinterval.construct.php
920920
*/
921921
public function __construct(#[LanguageLevelTypeAware(['8.0' => 'string'], default: '')] $duration) {}

0 commit comments

Comments
 (0)