lib/braintree/document_upload_gateway.rb in braintree-4.15.0 vs lib/braintree/document_upload_gateway.rb in braintree-4.16.0
- old
+ new
@@ -1,7 +1,7 @@
module Braintree
- class DocumentUploadGateway # :nodoc:
+ class DocumentUploadGateway
include BaseModule
def initialize(gateway)
@gateway = gateway
@config = gateway.config
@@ -15,17 +15,17 @@
def create!(*args)
return_object_or_raise(:document_upload) { create(*args) }
end
- def self._create_signature # :nodoc:
+ def self._create_signature
[
:kind,
:file
]
end
- def _do_create(path, params, file) # :nodoc:
+ def _do_create(path, params, file)
response = @config.http.post("#{@config.base_merchant_path}#{path}", params, file)
if response[:document_upload]
SuccessfulResult.new(:document_upload => DocumentUpload._new(response[:document_upload]))
elsif response[:api_error_response]
ErrorResult.new(@gateway, response[:api_error_response])