lib/stripe/account.rb in stripe-4.16.0 vs lib/stripe/account.rb in stripe-4.17.0

- old
+ new

@@ -12,10 +12,13 @@ OBJECT_NAME = "account".freeze custom_method :reject, http_verb: :post save_nested_resource :external_account + nested_resource_class_methods :capability, + operations: %i[retrieve update list], + resource_plural: "capabilities" nested_resource_class_methods :external_account, operations: %i[create retrieve update delete list] nested_resource_class_methods :login_link, operations: %i[create] nested_resource_class_methods :person, operations: %i[create retrieve update delete list] @@ -46,15 +49,17 @@ end super(id, opts) end def persons(params = {}, opts = {}) - resp, opts = request(:get, resource_url + "/persons", params, Util.normalize_opts(opts)) + resp, opts = request(:get, resource_url + "/persons", params, opts) Util.convert_to_stripe_object(resp.data, opts) end + # We are not adding a helper for capabilities here as the Account object already has a + # capabilities property which is a hash and not the sub-list of capabilities. + def reject(params = {}, opts = {}) - opts = Util.normalize_opts(opts) resp, opts = request(:post, resource_url + "/reject", params, opts) initialize_from(resp.data, opts) end # Somewhat unfortunately, we attempt to do a special encoding trick when