Skip to content

Commit

Permalink
SSL version is only 1.9+
Browse files Browse the repository at this point in the history
  • Loading branch information
jnunemaker committed Sep 7, 2012
1 parent b673389 commit fffc08d
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions lib/httparty/connection_adapter.rb
Expand Up @@ -106,6 +106,7 @@ def attach_ssl_certificates(http, options)
http.verify_mode = OpenSSL::SSL::VERIFY_PEER
end

# This is only Ruby 1.9+
if options[:ssl_version] && http.respond_to?(:ssl_version=)
http.ssl_version = options[:ssl_version]
end
Expand Down
2 changes: 1 addition & 1 deletion spec/httparty/connection_adapter_spec.rb
Expand Up @@ -84,7 +84,7 @@
it "sets ssl version" do
subject.ssl_version.should == :TLSv1
end
end
end if RUBY_VERSION > '1.9'
end

context "when timeout is not set" do
Expand Down

0 comments on commit fffc08d

Please sign in to comment.