\r
word = params[:word].downcase\r
url = @dmwapurl % URI.escape(word)\r
- xml = @bot.httputil.get_cached(url)\r
+ xml = nil\r
+ info = @bot.httputil.get_response(url) rescue nil\r
+ xml = info.body if info\r
if xml.nil?\r
- info = @bot.httputil.last_response\r
info = info ? " (#{info.code} - #{info.message})" : ""\r
return false if justcheck\r
m.reply "An error occurred while looking for #{word}#{info}"\r
word = params[:word].join\r
[word, word + "_1"].each { |check|\r
url = @oxurl % URI.escape(check)\r
- h = @bot.httputil.head(url)\r
+ h = @bot.httputil.head(url, :max_redir => 5)\r
if h\r
m.reply("#{word} found: #{url}") unless justcheck\r
return true\r
\r
word = params[:word].to_s.downcase\r
url = @chambersurl % URI.escape(word)\r
- xml = @bot.httputil.get_cached(url)\r
+ xml = nil\r
+ info = @bot.httputil.get_response(url) rescue nil\r
+ xml = info.body if info\r
case xml\r
when nil\r
- info = @bot.httputil.last_response\r
info = info ? " (#{info.code} - #{info.message})" : ""\r
return false if justcheck\r
m.reply "An error occurred while looking for #{word}#{info}"\r