aboutsummaryrefslogtreecommitdiffstats
path: root/activerecord/lib/active_record
diff options
context:
space:
mode:
authorRafael Mendonça França <rafaelmfranca@gmail.com>2014-09-22 14:23:40 -0300
committerRafael Mendonça França <rafaelmfranca@gmail.com>2014-09-22 14:23:40 -0300
commitb61a2db8d07146518c89bbf49176b093771af6d4 (patch)
tree76f386682896d1c822dc86c5cac87eded37830e3 /activerecord/lib/active_record
parent585e75696b31395aee895e5366e331c07c3f5ee1 (diff)
parentc36ca0547f41373fa3cd474722bc51e5446a1630 (diff)
downloadrails-b61a2db8d07146518c89bbf49176b093771af6d4.tar.gz
rails-b61a2db8d07146518c89bbf49176b093771af6d4.tar.bz2
rails-b61a2db8d07146518c89bbf49176b093771af6d4.zip
Merge pull request #17009 from arthurnn/foreign_key_symbols
Fixtures using Foreign key symbols
Diffstat (limited to 'activerecord/lib/active_record')
-rw-r--r--activerecord/lib/active_record/fixtures.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/activerecord/lib/active_record/fixtures.rb b/activerecord/lib/active_record/fixtures.rb
index 1724fa893d..4044f5f7b2 100644
--- a/activerecord/lib/active_record/fixtures.rb
+++ b/activerecord/lib/active_record/fixtures.rb
@@ -661,7 +661,7 @@ module ActiveRecord
row[association.foreign_type] = $1
end
- fk_type = association.active_record.columns_hash[association.foreign_key].type
+ fk_type = association.active_record.columns_hash[fk_name].type
row[fk_name] = ActiveRecord::FixtureSet.identify(value, fk_type)
end
when :has_many