public
nobgit
read
NobMail
Based on mailcow: dockerized
Languages
Repository composition by tracked source files.
PHP
49%
JavaScript
35%
HTML
9%
CSS
4%
Shell
2%
Python
1%
Lua
0%
Perl
0%
Ruby
0%
SCSS
0%
Create file
Wiki Documentation
Clone
https://nobgit.com/orgs/nobgit/nobmail.git
ssh://[email protected]:2222/orgs/nobgit/nobmail.git
Commit
[Web] fix blank /debug page with invalid timezone
a0e55cb9
data/web/debug.php | 10 +++++++---
1 file changed, 7 insertions(+), 3 deletions(-)
Diff
diff --git a/data/web/debug.php b/data/web/debug.php
index 52052f68..9c338009 100644
--- a/data/web/debug.php
+++ b/data/web/debug.php
@@ -39,9 +39,13 @@ foreach ($containers as $container => $container_info) {
$StartedAt['month'],
$StartedAt['day'],
$StartedAt['year']));
- $user_tz = new DateTimeZone(getenv('TZ'));
- $date->setTimezone($user_tz);
- $started = $date->format('r');
+ try {
+ $user_tz = new DateTimeZone(getenv('TZ'));
+ $date->setTimezone($user_tz);
+ $started = $date->format('r');
+ } catch(Exception $e) {
+ $started = '?';
+ }
}
else {
$started = '?';