diff options
author | Rafael Mendonça França <rafaelmfranca@gmail.com> | 2014-05-16 15:31:51 -0300 |
---|---|---|
committer | Rafael Mendonça França <rafaelmfranca@gmail.com> | 2014-05-16 15:31:51 -0300 |
commit | 0369dbfd42328a88e9ff2643c94900ce31dbf0c8 (patch) | |
tree | 86b9e1848c8b46e20e0909d52db0fa93b5cfffaf /activerecord | |
parent | e5f840ca4625a1a4fc7202202e1645aba30af38c (diff) | |
download | rails-0369dbfd42328a88e9ff2643c94900ce31dbf0c8.tar.gz rails-0369dbfd42328a88e9ff2643c94900ce31dbf0c8.tar.bz2 rails-0369dbfd42328a88e9ff2643c94900ce31dbf0c8.zip |
prepend mutates the string so we can remove the assignment
Diffstat (limited to 'activerecord')
-rw-r--r-- | activerecord/lib/active_record/associations/builder/has_and_belongs_to_many.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/activerecord/lib/active_record/associations/builder/has_and_belongs_to_many.rb b/activerecord/lib/active_record/associations/builder/has_and_belongs_to_many.rb index a297439214..afbf6dfb94 100644 --- a/activerecord/lib/active_record/associations/builder/has_and_belongs_to_many.rb +++ b/activerecord/lib/active_record/associations/builder/has_and_belongs_to_many.rb @@ -26,7 +26,7 @@ module ActiveRecord::Associations::Builder model_name = name.to_s.camelize.singularize if parent_name = lhs_class.parent_name - model_name = model_name.prepend("#{parent_name}::") + model_name.prepend("#{parent_name}::") end model_name |