bigcommerce-api-ruby
bigcommerce-api-ruby copied to clipboard
How Does One Persist Data with This Client‽
Where is this documented? I've look at the RDocs and at the specs (🙀) and nothing works!
rails [5.1.7] (bigcommerce-test)$ cust[0].class
=> Bigcommerce::Customer
rails [5.1.7] (bigcommerce-test)$ cust[0].class.update(cust[0].id, cust[0])
Traceback (most recent call last):
1: from (irb):30
NoMethodError (undefined method `put' for nil:NilClass)
Did you mean? puts
putc
rails [5.1.7] (bigcommerce-test)$ cust[0].class.update(cust[0].id, cust[0].to_h)
Traceback (most recent call last):
2: from (irb):31
1: from (irb):31:in `rescue in irb_binding'
NoMethodError (undefined method `put' for nil:NilClass)
rails [5.1.7] (bigcommerce-test)$ cust[0].update
=> #<Bigcommerce::Customer ...
Of course #update is silly Hashie method.
I did find this but given the example above update doesn't work :(