projects
/
civicrm-core.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
9fc1ccd
)
CRM-17072 fix timezone handling for UTF dates
author
eileenmcnaugton
<eileen@fuzion.co.nz>
Mon, 24 Aug 2015 00:09:06 +0000
(12:09 +1200)
committer
eileenmcnaugton
<eileen@fuzion.co.nz>
Mon, 24 Aug 2015 00:11:06 +0000
(12:11 +1200)
CRM/Utils/System/Base.php
patch
|
blob
|
blame
|
history
diff --git
a/CRM/Utils/System/Base.php
b/CRM/Utils/System/Base.php
index 866aeeafed11b172cbb36a1179a544dc58fab961..0e076d3126814b230e908b558ec82d00a268e834 100644
(file)
--- a/
CRM/Utils/System/Base.php
+++ b/
CRM/Utils/System/Base.php
@@
-548,6
+548,10
@@
abstract class CRM_Utils_System_Base {
public function getTimeZoneOffset() {
$timezone = $this->getTimeZoneString();
if ($timezone) {
+ if ($timezone == 'UTC') {
+ // CRM-17072 Let's short-circuit all the zero handling & return it here!
+ return '+00:00';
+ }
$tzObj = new DateTimeZone($timezone);
$dateTime = new DateTime("now", $tzObj);
$tz = $tzObj->getOffset($dateTime);