Fix ignoring time zone bug

This commit is contained in:
amir authored and GitHub committed 2021-01-02 13:53:58 +04:00
1 parent 608dccf9dc
commit 93476612ba
1 file changed
+1
+1
View File
@@ -35,6 +35,7 @@ trait Creator
try { try {
parent::__construct($datetime, static::createTimeZone($timezone)); parent::__construct($datetime, static::createTimeZone($timezone));
parent::setTimezone(static::createTimeZone($timezone));
} catch (Exception $exception) { } catch (Exception $exception) {
throw new InvalidArgumentException(sprintf("Unknown datetime '%s'", $datetime)); throw new InvalidArgumentException(sprintf("Unknown datetime '%s'", $datetime));
} }