Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Select an option

  • Save shopifypartners/c492742a448bae4739b2a5bb57338919 to your computer and use it in GitHub Desktop.

Select an option

Save shopifypartners/c492742a448bae4739b2a5bb57338919 to your computer and use it in GitHub Desktop.
products = ShopifyAPI::Product.find(:all, params: { order: 'inventory_total desc', limit: 250 })
process_products(products)
3.times do
break unless products.next_page?
products = products.fetch_next_page
process_products(products)
end
@amirmansha
Copy link
Copy Markdown

Informative code

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