From 1e67eb8281b6f3419546be691db03fd59c8128b0 Mon Sep 17 00:00:00 2001 From: Nemo Date: Thu, 30 Jul 2020 03:07:27 +0530 Subject: [PATCH] Remove commented code --- parse_restaurants.rb | 24 ------------------------ 1 file changed, 24 deletions(-) diff --git a/parse_restaurants.rb b/parse_restaurants.rb index a2a74c7..d512f4c 100644 --- a/parse_restaurants.rb +++ b/parse_restaurants.rb @@ -9,30 +9,6 @@ restaurants = [] csv = CSV.open("data/#{Date.today.to_s}-all.csv", 'w') -# restaurants = CSV.read("data/#{Date.today.to_s}.csv", headers: true) -# restaurants_map = {} - -# restaurants.each do |row| -# begin -# url = URI.parse(row['url']) -# rescue URI::InvalidURIError -# url = URI.parse(CGI.escape(row['url'])) -# end -# id = row['url'].split('/').last -# restaurants_map[url.path.strip] = { -# 'url': url, -# 'title': row['title'], -# 'location':row['location'], -# 'address':row['address'] -# } -# end - -# def join_props(h, key, data) -# data.keys.each do |k| -# h["#{key}.#{k}"] = data[k] -# end -# end - first = true Dir.glob('html/restaurants/*.html') do |file| # puts file