Sha256: b33a9db863a997bf1406277bce4ccde3723d08a49f626ff23f5999264e716551
Contents?: true
Size: 590 Bytes
Versions: 1
Compression:
Stored size: 590 Bytes
Contents
require "faraday" module Uploadcare module Connections class UploadConnection < Faraday::Connection def initialize options ca_path = '/etc/ssl/certs' if File.exists?('/etc/ssl/certs') super ssl: { ca_path: ca_path }, url: options[:upload_url_base] do |frd| frd.request :multipart frd.request :url_encoded frd.adapter :net_http frd.headers['User-Agent'] = Uploadcare::user_agent(options) frd.response :uploadcare_raise_error frd.response :uploadcare_parse_json end end end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
uploadcare-ruby-1.1.0 | lib/uploadcare/rest/connections/upload_connection.rb |