Add ability to specify custom headers for list_object.create

This commit is contained in:
Shale Craig 2014-12-16 15:46:08 -08:00
parent fd104697f3
commit 7c6c8269c6

View File

@ -20,9 +20,9 @@ module Stripe
Util.convert_to_stripe_object(response, api_key)
end
def create(params={}, api_key=nil)
def create(params={}, api_key=nil, headers={})
api_key ||= @api_key
response, api_key = Stripe.request(:post, url, api_key, params)
response, api_key = Stripe.request(:post, url, api_key, params, headers)
Util.convert_to_stripe_object(response, api_key)
end