From: Tom Gilbert Date: Thu, 26 Jan 2006 10:48:12 +0000 (+0000) Subject: reinstate the use of the bot's httputil. As soon as I tried this at work I X-Git-Url: https://git.netwichtig.de/gitweb/?a=commitdiff_plain;h=7881d147ffdd59fe67f1e48ebd13d645ea3a0292;p=user%2Fhenk%2Fcode%2Fruby%2Frbot.git reinstate the use of the bot's httputil. As soon as I tried this at work I realised we lost proxy support. --- diff --git a/data/rbot/plugins/url.rb b/data/rbot/plugins/url.rb index d48639de..57b43a61 100644 --- a/data/rbot/plugins/url.rb +++ b/data/rbot/plugins/url.rb @@ -37,7 +37,8 @@ class UrlPlugin < Plugin return if url.scheme !~ /https?/ puts "+ connecting to #{url.host}:#{url.port}" - title = Net::HTTP.start(url.host, url.port) do |http| + http = @bot.httputil.get_proxy(url) + title = http.start do |http| url.path = '/' if url.path == '' head = http.request_head(url.path) case head