Skip to content

Commit

Permalink
Trying to speed import
Browse files Browse the repository at this point in the history
  • Loading branch information
makenai committed Jun 28, 2012
1 parent eb2db7a commit d05165a
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions app/controllers/media_controller.rb
Expand Up @@ -98,7 +98,7 @@ def import
on_order = MediaLocation.find_by_name('On Order')
csv = CSV.parse( params[:file].read, :headers => true )
csv.each do |row|
if row[7]
# if row[7]
begin
if media = Media.amazon_lookup( row[0] )
media.location_id = on_order.try(:id)
Expand All @@ -116,7 +116,7 @@ def import
rescue Media::LookupException => e
puts e.message
end
end
# end
end
redirect_to media_index_url, :notice => "Imported #{count} items."
end
Expand Down

0 comments on commit d05165a

Please sign in to comment.