From 1158e734a90eef153204b4b68a428ff330287a07 Mon Sep 17 00:00:00 2001 From: a7x Date: Tue, 29 Jun 2010 04:11:58 +0200 Subject: Fixed googlefight.rb regex --- data/rbot/plugins/googlefight.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'data/rbot/plugins') diff --git a/data/rbot/plugins/googlefight.rb b/data/rbot/plugins/googlefight.rb index 0b9393ef..894d2233 100755 --- a/data/rbot/plugins/googlefight.rb +++ b/data/rbot/plugins/googlefight.rb @@ -54,7 +54,7 @@ class GoogleFightPlugin < Plugin def google_count(query) url = 'http://www.google.com/search?hl=en&safe=off&btnG=Search&q=' << CGI.escape(query) html = Net::HTTP.get(URI.parse((url))) - res = html.scan(%r{Results 1 - \d+ of(?: about)? ([\d,]+)}) + res = html.scan(%r{>About ([\d,]+) results}) res.to_s.tr(",", "").to_i end end -- cgit v1.2.3