Permalink
Browse files

Remove unused parameter in ::instantiate_fixtures

Second parameter of Fixtures::instantiate_fixtures was not used, so i removed it.
  • Loading branch information...
1 parent f1cc45e commit af44c2ba4a82cf21842071d7c7711de086768f2f @alexeymuranov alexeymuranov committed Dec 31, 2011
Showing with 5 additions and 5 deletions.
  1. +5 −5 activerecord/lib/active_record/fixtures.rb
@@ -411,7 +411,7 @@ def self.cache_fixtures(connection, fixtures_map)
cache_for_connection(connection).update(fixtures_map)
end
- def self.instantiate_fixtures(object, fixture_name, fixtures, load_instances = true)
+ def self.instantiate_fixtures(object, fixtures, load_instances = true)
if load_instances
fixtures.each do |name, fixture|
begin
@@ -424,8 +424,8 @@ def self.instantiate_fixtures(object, fixture_name, fixtures, load_instances = t
end
def self.instantiate_all_loaded_fixtures(object, load_instances = true)
- all_loaded_fixtures.each do |table_name, fixtures|
- ActiveRecord::Fixtures.instantiate_fixtures(object, table_name, fixtures, load_instances)
+ all_loaded_fixtures.each_value do |fixtures|
+ instantiate_fixtures(object, fixtures, load_instances)
end
end
@@ -901,8 +901,8 @@ def instantiate_fixtures
ActiveRecord::Fixtures.instantiate_all_loaded_fixtures(self, load_instances?)
else
raise RuntimeError, 'Load fixtures before instantiating them.' if @loaded_fixtures.nil?
- @loaded_fixtures.each do |fixture_name, fixtures|
- ActiveRecord::Fixtures.instantiate_fixtures(self, fixture_name, fixtures, load_instances?)
+ @loaded_fixtures.each_value do |fixtures|
+ ActiveRecord::Fixtures.instantiate_fixtures(self, fixtures, load_instances?)
end
end
end

0 comments on commit af44c2b

Please sign in to comment.