Timezone calculation error

andygoneawol - November 14, 2008 - 01:23
Project:Announcements
Version:6.x-1.2
Component:Code
Category:bug report
Priority:normal
Assigned:Unassigned
Status:closed
Description

In _announcements_unixtime2drupaldate, the time is decremented by the address of _announcements_get_timezone. It should be incremented by its return value:

function _announcements_unixtime2drupaldate($unixtime) {
// $unixtime -= _announcements_get_timezone;
$unixtime += _announcements_get_timezone(); /* BUG FIX */
return array('day' => gmdate('j', $unixtime),
'month' => gmdate('n', $unixtime),
'year' => gmdate('Y', $unixtime));
}

#1

NancyDru - November 14, 2008 - 16:25
Status:active» fixed

Fix committed on both branches.

#2

System Message - November 28, 2008 - 16:32
Status:fixed» closed

Automatically closed -- issue fixed for two weeks with no activity.

 
 

Drupal is a registered trademark of Dries Buytaert.