Skip to content

Commit

Permalink
Add time_zone_aware_types to application.rb
Browse files Browse the repository at this point in the history
  • Loading branch information
alfiehub committed Apr 9, 2019
1 parent 10f9219 commit 06e1f20
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions config/application.rb
Expand Up @@ -77,6 +77,10 @@ class Application < Rails::Application
# Fortastic options
Formtastic::FormBuilder.use_required_attribute = true
Formtastic::FormBuilder.perform_browser_validations = true

# Time columns will become time zone aware in Rails 5.1. This still causes `String`s to be parsed as if they were in `Time.zone`, and `Time`s to be converted to `Time.zone`.
# To keep the old behavior, you must add the following to your initializer:
config.active_record.time_zone_aware_types = [:datetime]
end

Haml::Template.options[:format] = :html5
Expand Down

0 comments on commit 06e1f20

Please sign in to comment.