Skip to content
This repository has been archived by the owner on Jun 13, 2018. It is now read-only.

Commit

Permalink
Sync posts_data.rb with ActiveMerchant
Browse files Browse the repository at this point in the history
  • Loading branch information
Cody Fauser committed Jul 4, 2008
1 parent 9c5098e commit 2842d7f
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
1 change: 1 addition & 0 deletions CHANGELOG
@@ -1 +1,2 @@
* Sync posts_data.rb with ActiveMerchant [cody]
* Don't use credentials fixtures in local tests [cody]
5 changes: 4 additions & 1 deletion lib/active_shipping/lib/posts_data.rb
Expand Up @@ -11,7 +11,7 @@ module PostsData #:nodoc:
READ_TIMEOUT = 60

def self.included(base)
base.class_inheritable_accessor :ssl_strict
base.superclass_delegating_accessor :ssl_strict
base.ssl_strict = true

base.class_inheritable_accessor :pem_password
Expand All @@ -22,6 +22,9 @@ def self.included(base)
end

def ssl_post(url, data, headers = {})
# Ruby 1.8.4 doesn't automatically set this header
headers['Content-Type'] ||= "application/x-www-form-urlencoded"

uri = URI.parse(url)

http = Net::HTTP.new(uri.host, uri.port)
Expand Down

0 comments on commit 2842d7f

Please sign in to comment.