Skip to content

Commit

Permalink
rails default 5.0
Browse files Browse the repository at this point in the history
```
irb(main):003:0> ActiveRecord::Base.belongs_to_required_by_default
=> false
irb(main):004:0> Rails.application.config.active_record.belongs_to_required_by_default
=> false
```
  • Loading branch information
ta1kt0me committed Dec 5, 2017
1 parent 7963742 commit 3e03f9f
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions config/initializers/new_framework_defaults.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
# Require `belongs_to` associations by default. Previous versions had false.
Rails.application.config.active_record.belongs_to_required_by_default = false

0 comments on commit 3e03f9f

Please sign in to comment.