From 6862a3a010c3299bb43fbccdd726d5cd08e695f3 Mon Sep 17 00:00:00 2001 From: "M. Hecker" Date: Wed, 26 Nov 2014 02:22:09 +0100 Subject: [urban] fix for changed markup --- data/rbot/plugins/urban.rb | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'data/rbot/plugins') diff --git a/data/rbot/plugins/urban.rb b/data/rbot/plugins/urban.rb index a23f8742..6d01c625 100644 --- a/data/rbot/plugins/urban.rb +++ b/data/rbot/plugins/urban.rb @@ -21,13 +21,15 @@ class UrbanPlugin < Plugin notfound = s.match %r{.*? isn't defined} - numpages = if s[%r{
.*?
}m] - $&.scan(/\d+/).collect {|x| x.to_i}.max || 1 + numpages = if s[%r{}m] + debug 'foo->' + debug $& + $&.scan(/>(\d+)]*>.*?]* href="\/define[^>]*>([^<]+).*?
(.+?)
.*?
(.+?)
}m) do |wrd, desc, ex| rv << [num, wrd.strip, desc.strip, ex.strip] num += 1 end -- cgit v1.2.3