mirror of
https://github.com/fergalmoran/mailcow-dockerized.git
synced 2025-12-22 09:27:30 +00:00
[Web] fix blank /debug page with invalid timezone
This commit is contained in:
@@ -39,9 +39,13 @@ foreach ($containers as $container => $container_info) {
|
|||||||
$StartedAt['month'],
|
$StartedAt['month'],
|
||||||
$StartedAt['day'],
|
$StartedAt['day'],
|
||||||
$StartedAt['year']));
|
$StartedAt['year']));
|
||||||
$user_tz = new DateTimeZone(getenv('TZ'));
|
try {
|
||||||
$date->setTimezone($user_tz);
|
$user_tz = new DateTimeZone(getenv('TZ'));
|
||||||
$started = $date->format('r');
|
$date->setTimezone($user_tz);
|
||||||
|
$started = $date->format('r');
|
||||||
|
} catch(Exception $e) {
|
||||||
|
$started = '?';
|
||||||
|
}
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
$started = '?';
|
$started = '?';
|
||||||
|
|||||||
Reference in New Issue
Block a user