提交 17ff70ac 编写于 作者: M Michael Koziarski

Make rake load_fixtures work with the new, flexible, fixtures api. [Rick Olson]. Closes #3995


git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@3706 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
上级 a117d68f
......@@ -238,7 +238,7 @@ def self.instantiate_all_loaded_fixtures(object, load_instances=true)
self.all_loaded_fixtures = {}
def self.create_fixtures(fixtures_directory, table_names, class_names = {})
table_names = table_names.flatten.map { |n| n.to_s }
table_names = [table_names].flatten.map { |n| n.to_s }
connection = block_given? ? yield : ActiveRecord::Base.connection
ActiveRecord::Base.silence do
fixtures_map = {}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册