diff options
author | Louise Crow <louise.crow@gmail.com> | 2013-06-04 15:03:02 +0100 |
---|---|---|
committer | Louise Crow <louise.crow@gmail.com> | 2013-06-04 15:03:02 +0100 |
commit | a885764b65916020d9182073b38f6951a20d4b8c (patch) | |
tree | 0988651c144b65a8e46b28b376b2e72a5947d934 /lib/timezone_fixes.rb | |
parent | eb1c465162420ad62c16dccb983cb28aa89a4639 (diff) | |
parent | a919141992a40599f99b32bd4a8312a0009f3f7a (diff) |
Merge branch 'release/0.11'0.11.0.3
Diffstat (limited to 'lib/timezone_fixes.rb')
-rw-r--r-- | lib/timezone_fixes.rb | 26 |
1 files changed, 0 insertions, 26 deletions
diff --git a/lib/timezone_fixes.rb b/lib/timezone_fixes.rb deleted file mode 100644 index 1bf326ccd..000000000 --- a/lib/timezone_fixes.rb +++ /dev/null @@ -1,26 +0,0 @@ -# Taken from -# https://rails.lighthouseapp.com/projects/8994/tickets/2946 -# http://github.com/rails/rails/commit/6f97ad07ded847f29159baf71050c63f04282170 - -# Otherwise times get stored wrong during British Summer Time - -# Hopefully fixed in later Rails. There is a test in spec/lib/timezone_fixes_spec.rb - -# This fix is applied in Rails 3.x. So, should be possible to remove this then! - -# Monkeypatch! -module ActiveRecord - module ConnectionAdapters # :nodoc: - module Quoting - def quoted_date(value) - if value.acts_like?(:time) - zone_conversion_method = ActiveRecord::Base.default_timezone == :utc ? :getutc : :getlocal - value.respond_to?(zone_conversion_method) ? value.send(zone_conversion_method) : value - else - value - end.to_s(:db) - end - end - end -end - |