Fix for bug 2916, silly silly named constant mistake.

Since we 're at it, fixed another bug: automatic recalculation of DST table
without having to logout if the user changes his timezone now works correctly.
This commit is contained in:
defacer
2005-04-14 12:20:09 +00:00
parent 1dfa369bd3
commit 4f2dbde9f8
+2 -1
View File
@@ -860,7 +860,7 @@ function get_user_timezone_offset($tz = 99) {
if (empty($tzrecord)) {
return 99.0;
}
return (float)$tzrecord->gmtoff / HOURSECS;
return (float)$tzrecord->gmtoff / HOURMINS;
}
}
@@ -916,6 +916,7 @@ function calculate_user_dst_table($from_year = NULL, $to_year = NULL) {
if (!empty($USER->dstoffsettz) && $USER->dstoffsettz != $usertz) {
// We have precalculated values, but the user's effective TZ has changed in the meantime, so reset
unset($USER->dstoffsets);
unset($USER->dstrange);
}
if (!empty($USER->dstoffsets) && empty($from_year) && empty($to_year)) {