Skip to content

Instantly share code, notes, and snippets.

@jeffdeville
Created July 20, 2010 03:18
Show Gist options
  • Save jeffdeville/482437 to your computer and use it in GitHub Desktop.
Save jeffdeville/482437 to your computer and use it in GitHub Desktop.
if top_sellers.class.inspect == "Array"
asins = top_sellers.collect {|item| item.get('asin') }
elsif !top_sellers.nil?
asins = [top_sellers.get('asin')]
end
asins = asins || []
@jeffdeville
Copy link
Author

thank you for the help xiaods!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment