diff options
author | Rafael Mendonça França <rafaelmfranca@gmail.com> | 2018-10-02 16:04:23 -0400 |
---|---|---|
committer | Rafael Mendonça França <rafaelmfranca@gmail.com> | 2018-10-02 16:04:23 -0400 |
commit | 92fece96da28d9f641bc8a8db1187b91c94cabfb (patch) | |
tree | b42943a968ce869a9d716b1f798e861d7700bffb /activerecord/lib/active_record/associations/builder/collection_association.rb | |
parent | 59a6ba4bd585f53a02b118011599b835e47773ea (diff) | |
parent | c401c43850e79a4d994e22dd8d82a69612bb947f (diff) | |
download | rails-92fece96da28d9f641bc8a8db1187b91c94cabfb.tar.gz rails-92fece96da28d9f641bc8a8db1187b91c94cabfb.tar.bz2 rails-92fece96da28d9f641bc8a8db1187b91c94cabfb.zip |
Merge pull request #34051 from gmcgibbon/module_parent_method_rename
Prefix Module#parent, Module#parents, and Module#parent_name with module
Diffstat (limited to 'activerecord/lib/active_record/associations/builder/collection_association.rb')
-rw-r--r-- | activerecord/lib/active_record/associations/builder/collection_association.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/activerecord/lib/active_record/associations/builder/collection_association.rb b/activerecord/lib/active_record/associations/builder/collection_association.rb index 35a72c3850..ff57c40121 100644 --- a/activerecord/lib/active_record/associations/builder/collection_association.rb +++ b/activerecord/lib/active_record/associations/builder/collection_association.rb @@ -24,7 +24,7 @@ module ActiveRecord::Associations::Builder # :nodoc: if block_given? extension_module_name = "#{model.name.demodulize}#{name.to_s.camelize}AssociationExtension" extension = Module.new(&Proc.new) - model.parent.const_set(extension_module_name, extension) + model.module_parent.const_set(extension_module_name, extension) end end |