Sha256: 4dccf8f6f3da5efafe8bc2877b38d4a167ff50084a4af15ad55c0ab8c479921d

Contents?: true

Size: 646 Bytes

Versions: 11

Compression:

Stored size: 646 Bytes

Contents

require 'active_support/core_ext/module/attribute_accessors'
require 'active_support/core_ext/module/remove_method'

module DateAndTime
  module Compatibility
    # If true, +to_time+ preserves the timezone offset of receiver.
    #
    # NOTE: With Ruby 2.4+ the default for +to_time+ changed from
    # converting to the local system time, to preserving the offset
    # of the receiver. For backwards compatibility we're overriding
    # this behavior, but new apps will have an initializer that sets
    # this to true, because the new behavior is preferred.
    mattr_accessor(:preserve_timezone, instance_writer: false) { false }
  end
end

Version data entries

11 entries across 11 versions & 2 rubygems

Version Path
activesupport-4.2.11.3 lib/active_support/core_ext/date_and_time/compatibility.rb
activesupport-4.2.11.2 lib/active_support/core_ext/date_and_time/compatibility.rb
cocoapods-dependency-html-0.0.2 vendor/bundle/gems/activesupport-4.2.11.1/lib/active_support/core_ext/date_and_time/compatibility.rb
cocoapods-dependency-html-0.0.1 vendor/bundle/gems/activesupport-4.2.11.1/lib/active_support/core_ext/date_and_time/compatibility.rb
activesupport-4.2.11.1 lib/active_support/core_ext/date_and_time/compatibility.rb
activesupport-4.2.11 lib/active_support/core_ext/date_and_time/compatibility.rb
activesupport-4.2.10 lib/active_support/core_ext/date_and_time/compatibility.rb
activesupport-4.2.10.rc1 lib/active_support/core_ext/date_and_time/compatibility.rb
activesupport-4.2.9 lib/active_support/core_ext/date_and_time/compatibility.rb
activesupport-4.2.9.rc2 lib/active_support/core_ext/date_and_time/compatibility.rb
activesupport-4.2.9.rc1 lib/active_support/core_ext/date_and_time/compatibility.rb