hulihanapplications / fletcher

A cross-website product information fetcher for ruby.
http://www.hulihanapplications.com
MIT License
53 stars 12 forks source link

Problems with Red/Yellow Product Titles on ThinkGeek #10

Closed dhulihan closed 11 years ago

dhulihan commented 11 years ago

When you enter a url for a think geek product, fletcher won't fetch the proper information when the product link is red (Gadgets) or yellow (T-shirts & Apparel). Here's an example of one that isn't working:

http://www.thinkgeek.com/product/f131/?pfm=tshirts-apparel_newest_f131_1

dhulihan commented 11 years ago

Looks like it's being caused by the hyphen in the price range:

> Fletcher.fetch("http://www.thinkgeek.com/product/f131/?pfm=tshirts-apparel_newest_f131_1")
ArgumentError: Invalid currency amount (hyphen)
dhulihan commented 11 years ago

Fixed in d0a07d94fb7669f6399d1d0e8a18d66c37b43bd6. Added spec test for this condition. Passing nicely.