parent
0aba7c4ac0
commit
1ec29d83eb
|
@ -206,10 +206,11 @@ class Exif
|
||||||
|
|
||||||
// Set timezone to system timezone
|
// Set timezone to system timezone
|
||||||
$tz = getenv('TZ') ?: date_default_timezone_get();
|
$tz = getenv('TZ') ?: date_default_timezone_get();
|
||||||
|
|
||||||
try {
|
try {
|
||||||
$dt->setTimezone(new \DateTimeZone($tz));
|
$dt->setTimezone(new \DateTimeZone($tz));
|
||||||
} catch (\Exception $e) {
|
} catch (\Exception $e) {
|
||||||
throw new \Error("FATAL: system timezone is invalid (TZ): $tz");
|
throw new \Error("FATAL: system timezone is invalid (TZ): {$tz}");
|
||||||
}
|
}
|
||||||
|
|
||||||
return self::forgetTimezone($dt);
|
return self::forgetTimezone($dt);
|
||||||
|
|
Loading…
Reference in New Issue