lib/stripe/util.rb in stripe-2.4.0 vs lib/stripe/util.rb in stripe-2.5.0

- old
+ new

@@ -72,10 +72,10 @@ # ==== Attributes # # * +data+ - Hash of fields and values to be converted into a StripeObject. # * +opts+ - Options for +StripeObject+ like an API key that will be reused # on subsequent API calls. - def self.convert_to_stripe_object(data, opts) + def self.convert_to_stripe_object(data, opts = {}) case data when Array data.map { |i| convert_to_stripe_object(i, opts) } when Hash # Try converting to a known object class. If none available, fall back to generic StripeObject