Skip to content

Commit

Permalink
Remove UsageRecord.create method (#826)
Browse files Browse the repository at this point in the history
  • Loading branch information
ob-stripe authored Aug 13, 2019
1 parent 5695b26 commit d31da77
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 45 deletions.
17 changes: 0 additions & 17 deletions lib/stripe/resources/usage_record.rb
Original file line number Diff line number Diff line change
Expand Up @@ -3,22 +3,5 @@
module Stripe
class UsageRecord < APIResource
OBJECT_NAME = "usage_record"

def self.create(params = {}, opts = {})
unless params.key?(:subscription_item)
raise ArgumentError, "Params must have a subscription_item key"
end

req_params = params.clone.delete_if do |key, _value|
key == :subscription_item
end
resp, opts = request(
:post,
"/v1/subscription_items/#{params[:subscription_item]}/usage_records",
req_params,
opts
)
Util.convert_to_stripe_object(resp.data, opts)
end
end
end
28 changes: 0 additions & 28 deletions test/stripe/usage_record_test.rb

This file was deleted.

0 comments on commit d31da77

Please sign in to comment.