Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Merge pull request #4514 from brainopia/update_timezone_offets

Update time zone offset information
  • Loading branch information...
commit 423241c066d1c397841d3709975bef81fd47bafd 1 parent 5da6b6e
Aaron Patterson tenderlove authored
2  activesupport/lib/active_support/core_ext/date_time/calculations.rb
View
@@ -4,7 +4,7 @@ class DateTime
class << self
# DateTimes aren't aware of DST rules, so use a consistent non-DST offset when creating a DateTime with an offset in the local zone
def local_offset
- ::Time.local(2007).utc_offset.to_r / 86400
+ ::Time.local(2012).utc_offset.to_r / 86400
end
# Returns <tt>Time.zone.now.to_datetime</tt> when <tt>Time.zone</tt> or <tt>config.time_zone</tt> are set, otherwise returns <tt>Time.now.to_datetime</tt>.
Please sign in to comment.
Something went wrong with that request. Please try again.