mirror of
https://github.com/hkalexling/Mango.git
synced 2026-04-05 00:00:44 -04:00
Check bool environment variables are "1" or "true"
This commit is contained in:
@@ -86,9 +86,7 @@ module HTTP
|
||||
class Client
|
||||
private def self.exec(uri : URI, tls : TLSContext = nil)
|
||||
previous_def uri, tls do |client, path|
|
||||
disable_ssl_verification = ENV["DISABLE_SSL_VERIFICATION"]? ||
|
||||
ENV["disable_ssl_verification"]?
|
||||
if disable_ssl_verification && client.tls?
|
||||
if client.tls? && env_is_true? "DISABLE_SSL_VERIFICATION"
|
||||
Logger.debug "Disabling SSL verification"
|
||||
client.tls.verify_mode = OpenSSL::SSL::VerifyMode::NONE
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user