mirror of
				https://github.com/stripe/stripe-ruby.git
				synced 2025-11-04 00:01:47 -05:00 
			
		
		
		
	* Rename the `Update` operation to `Save` * Add the `update` class method to all saveable resources * Add tests for update method * Add tests for plans, invoice items, and application fees
		
			
				
	
	
		
			19 lines
		
	
	
		
			694 B
		
	
	
	
		
			Ruby
		
	
	
	
	
	
			
		
		
	
	
			19 lines
		
	
	
		
			694 B
		
	
	
	
		
			Ruby
		
	
	
	
	
	
module Stripe
 | 
						|
  class ApplicationFeeRefund < APIResource
 | 
						|
    include Stripe::APIOperations::Save
 | 
						|
    extend Stripe::APIOperations::List
 | 
						|
 | 
						|
    def resource_url
 | 
						|
      "#{ApplicationFee.resource_url}/#{CGI.escape(fee)}/refunds/#{CGI.escape(id)}"
 | 
						|
    end
 | 
						|
 | 
						|
    def self.update(id, params=nil, opts=nil)
 | 
						|
      raise NotImplementedError.new("Refunds cannot be updated without an application fee ID. Update a refund by using `a = appfee.refunds.retrieve('refund_id'); a.save`")
 | 
						|
    end
 | 
						|
 | 
						|
    def self.retrieve(id, api_key=nil)
 | 
						|
      raise NotImplementedError.new("Refunds cannot be retrieved without an application fee ID. Retrieve a refund using appfee.refunds.retrieve('refund_id')")
 | 
						|
    end
 | 
						|
  end
 | 
						|
end
 |