From 49b601386a7e1ff29a2bd4fd87e962d006aab733 Mon Sep 17 00:00:00 2001 From: Tim Otten Date: Mon, 3 Dec 2018 22:35:50 -0800 Subject: [PATCH] CRM-19115 - Synchronize PHP=>MySQL active timezone for all backend scripts --- CRM/Utils/System.php | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/CRM/Utils/System.php b/CRM/Utils/System.php index ab86071241..b335c01977 100644 --- a/CRM/Utils/System.php +++ b/CRM/Utils/System.php @@ -1474,7 +1474,11 @@ class CRM_Utils_System { $params = array(); } $config = CRM_Core_Config::singleton(); - return $config->userSystem->loadBootStrap($params, $loadUser, $throwError, $realPath); + $result = $config->userSystem->loadBootStrap($params, $loadUser, $throwError, $realPath); + if (is_callable([$config->userSystem, 'setMySQLTimeZone'])) { + $config->userSystem->setMySQLTimeZone(); + } + return $result; } /** -- 2.25.1