From 782a596c8f01060d22b44151e9dbd60a8ef138d6 Mon Sep 17 00:00:00 2001 From: Andy Brody Date: Wed, 15 Apr 2015 16:43:17 -0700 Subject: [PATCH] Fix error when SSL verification is disabled. Fixes #242 --- lib/stripe.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/stripe.rb b/lib/stripe.rb index 146b894e..7e37b6de 100644 --- a/lib/stripe.rb +++ b/lib/stripe.rb @@ -96,12 +96,12 @@ module Stripe request_opts = {:verify_ssl => OpenSSL::SSL::VERIFY_PEER, :ssl_ca_file => @ssl_bundle_path} else + request_opts = {:verify_ssl => false} unless @verify_ssl_warned @verify_ssl_warned = true $stderr.puts("WARNING: Running without SSL cert verification. " \ "You should never do this in production. " \ "Execute 'Stripe.verify_ssl_certs = true' to enable verification.") - request_opts = {:verify_ssl => false} end end