Catch errors in user's timezone settings
This commit is contained in:
parent
e7ea756cdb
commit
b95a4d19b7
1 changed files with 7 additions and 1 deletions
|
@ -45,7 +45,13 @@ class libkolab extends rcube_plugin
|
|||
set_include_path($include_path);
|
||||
|
||||
$rcmail = rcmail::get_instance();
|
||||
kolab_format::$timezone = new DateTimeZone($rcmail->config->get('timezone', 'GMT'));
|
||||
try {
|
||||
kolab_format::$timezone = new DateTimeZone($rcmail->config->get('timezone', 'GMT'));
|
||||
}
|
||||
catch (Exception $e) {
|
||||
raise_error($e, true);
|
||||
kolab_format::$timezone = new DateTimeZone('GMT');
|
||||
}
|
||||
|
||||
// load (old) dependencies if available
|
||||
if (@include_once('Horde/Util.php')) {
|
||||
|
|
Loading…
Add table
Reference in a new issue