@@ -545,7 +545,7 @@ public function setYear($value)
545545 public function setMonth ($ value )
546546 {
547547 if (is_numeric ($ value ) && ($ value < 1 || $ value > 12 )) {
548- throw I18nException::forInvalidMonth ($ value );
548+ throw I18nException::forInvalidMonth (( string ) $ value );
549549 }
550550
551551 if (is_string ($ value ) && ! is_numeric ($ value )) {
@@ -567,13 +567,13 @@ public function setMonth($value)
567567 public function setDay ($ value )
568568 {
569569 if ($ value < 1 || $ value > 31 ) {
570- throw I18nException::forInvalidDay ($ value );
570+ throw I18nException::forInvalidDay (( string ) $ value );
571571 }
572572
573573 $ date = $ this ->getYear () . '- ' . $ this ->getMonth ();
574574 $ lastDay = date ('t ' , strtotime ($ date ));
575575 if ($ value > $ lastDay ) {
576- throw I18nException::forInvalidOverDay ($ lastDay , $ value );
576+ throw I18nException::forInvalidOverDay ($ lastDay , ( string ) $ value );
577577 }
578578
579579 return $ this ->setValue ('day ' , $ value );
@@ -591,7 +591,7 @@ public function setDay($value)
591591 public function setHour ($ value )
592592 {
593593 if ($ value < 0 || $ value > 23 ) {
594- throw I18nException::forInvalidHour ($ value );
594+ throw I18nException::forInvalidHour (( string ) $ value );
595595 }
596596
597597 return $ this ->setValue ('hour ' , $ value );
@@ -609,7 +609,7 @@ public function setHour($value)
609609 public function setMinute ($ value )
610610 {
611611 if ($ value < 0 || $ value > 59 ) {
612- throw I18nException::forInvalidMinutes ($ value );
612+ throw I18nException::forInvalidMinutes (( string ) $ value );
613613 }
614614
615615 return $ this ->setValue ('minute ' , $ value );
@@ -627,7 +627,7 @@ public function setMinute($value)
627627 public function setSecond ($ value )
628628 {
629629 if ($ value < 0 || $ value > 59 ) {
630- throw I18nException::forInvalidSeconds ($ value );
630+ throw I18nException::forInvalidSeconds (( string ) $ value );
631631 }
632632
633633 return $ this ->setValue ('second ' , $ value );
0 commit comments