Permalink
Browse files

Disabling tradus.in

Based on feedback by Feroz regarding junk results for ISBN search
  • Loading branch information...
1 parent aac1b75 commit f79ff42c15903ebb67750dc75565b0b8108043ef @swaroopch committed Jan 30, 2012
Showing with 13 additions and 12 deletions.
  1. +13 −12 app/models/bookprice.rb
View
@@ -193,18 +193,19 @@ def search_uread(isbn)
end
end
- def search_tradus(isbn)
- url = "http://www.tradus.in/search/tradus_search/#{isbn}"
- page = self.fetch_page(url)
- unless page.nil?
- text = page.search("div.productPrice").first
- text = text.text unless text.blank?
- text = "" if text.blank?
- { :price => find_price_at_end(text), :url => url }
- else
- { :price => NOT_AVAILABLE, :url => url }
- end
- end
+ ## NOTE Disabled because it shows junk results for ISBN search
+ #def search_tradus(isbn)
+ #url = "http://www.tradus.in/search/tradus_search/#{isbn}"
+ #page = self.fetch_page(url)
+ #unless page.nil?
+ #text = page.search("div.productPrice").first
+ #text = text.text unless text.blank?
+ #text = "" if text.blank?
+ #{ :price => find_price_at_end(text), :url => url }
+ #else
+ #{ :price => NOT_AVAILABLE, :url => url }
+ #end
+ #end
## NOTE Disabled because it always gives a 404
#def search_jumadi(isbn)

0 comments on commit f79ff42

Please sign in to comment.