From 52f4457cf8aad0de59b7bd83e86b6cab228a45d6 Mon Sep 17 00:00:00 2001 From: Dmitry Kim Date: Sat, 14 Apr 2007 16:25:45 +0000 Subject: * (plugins/urban) do not cache "random" lookups --- data/rbot/plugins/urban.rb | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'data/rbot/plugins') diff --git a/data/rbot/plugins/urban.rb b/data/rbot/plugins/urban.rb index 9b547644..0c7d9838 100644 --- a/data/rbot/plugins/urban.rb +++ b/data/rbot/plugins/urban.rb @@ -10,7 +10,8 @@ class UrbanPlugin < Plugin if words.empty? resp = @bot.httputil.head('http://www.urbandictionary.com/random.php', - :max_redir => -1) + :max_redir => -1, + :cache => false) if resp.code == "302" && (loc = resp['location']) words = URI.unescape(loc.match(/define.php\?term=(.*)$/)[1]) rescue nil end -- cgit v1.2.3