lib/rsqoot/merchant.rb in rsqoot-0.2.2 vs lib/rsqoot/merchant.rb in rsqoot-0.3.0

- old
+ new

@@ -5,9 +5,13 @@ # # @param [String] id (The merchant's ID, Use the Sqoot ID or ID for any supported namespace. Must supply namespace if we don't use Sqoot) # @param [String] namespace (One of the supported namespaces. Factual, Foursquare, Facebook, Google, CitySearch, Yelp.) def merchant(id, options={}) - get("merchants/#{id}", options) + if merchant_not_latest?(id) + @rsqoot_merchant = get("merchants/#{id}", options) + @rsqoot_merchant = @rsqoot_merchant.merchant if @rsqoot_merchant + end + @rsqoot_merchant end end end \ No newline at end of file