"TypeError: compared with non class/module" when calling ShopifyAPI::Product.new

Skeezy
New Member
1 0 0

I'm using the ruby gem shopify_api v.9.4.1 and am getting a TypeError when trying to create a new Shopify product with ShopifyAPI::Product.new. My code gem was previously having no issues on gem version 8.1.0.

 

  def build_shopify_product
    product = ShopifyAPI::Product.new # gives error here
    product.title = title
    product.product_type = 'Course'
    product
  end

 

 Gemfile:

 

gem 'shopify_api', '~> 9.4', '>= 9.4.1'

 

0 Likes