mirror of
https://github.com/hkalexling/Mango.git
synced 2025-08-02 10:55:30 -04:00
Allow proxy with authentication
This commit is contained in:
parent
aa5e999ed4
commit
df4deb1415
@ -35,7 +35,8 @@ private def env_to_proxy(key : String) : HTTP::Proxy::Client?
|
||||
|
||||
begin
|
||||
uri = URI.parse val
|
||||
HTTP::Proxy::Client.new uri.hostname.not_nil!, uri.port.not_nil!
|
||||
HTTP::Proxy::Client.new uri.hostname.not_nil!, uri.port.not_nil!,
|
||||
username: uri.user, password: uri.password
|
||||
rescue
|
||||
nil
|
||||
end
|
||||
|
Loading…
x
Reference in New Issue
Block a user