Skip to content
Browse files

No need to `readlines` then `join`, just use `read` :heart:

  • Loading branch information...
1 parent bb95e81 commit 4c1a1933cbc5ab96efe340a3b31ac5fee12c99c8 @tenderlove tenderlove committed Nov 16, 2011
Showing with 1 addition and 1 deletion.
  1. +1 −1 activerecord/lib/active_record/railties/databases.rake
View
2 activerecord/lib/active_record/railties/databases.rake
@@ -414,7 +414,7 @@ db_namespace = namespace :db do
when /mysql/
ActiveRecord::Base.establish_connection(abcs[env])
ActiveRecord::Base.connection.execute('SET foreign_key_checks = 0')
- IO.readlines("#{Rails.root}/db/structure.sql").join.split("\n\n").each do |table|
+ IO.read("#{Rails.root}/db/structure.sql").split("\n\n").each do |table|
ActiveRecord::Base.connection.execute(table)
end
when /postgresql/

0 comments on commit 4c1a193

Please sign in to comment.
Something went wrong with that request. Please try again.