diff options
author | Matthias H <apoc@sixserv.org> | 2013-08-18 12:26:39 +0200 |
---|---|---|
committer | Matthias H <apoc@sixserv.org> | 2013-08-18 12:26:39 +0200 |
commit | 4b71dc02e70e7df55fda47813f850d035cdf5b36 (patch) | |
tree | 08853ba7415653ef838438d1a3996ba54557c778 /data/rbot/plugins/games | |
parent | 8ecbb72e7ad7159addea86a6acac1fb97348c9dd (diff) |
azgame: catch scraping error
Diffstat (limited to 'data/rbot/plugins/games')
-rw-r--r-- | data/rbot/plugins/games/azgame.rb | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/data/rbot/plugins/games/azgame.rb b/data/rbot/plugins/games/azgame.rb index a19da43c..91caf35d 100644 --- a/data/rbot/plugins/games/azgame.rb +++ b/data/rbot/plugins/games/azgame.rb @@ -560,6 +560,7 @@ class AzGamePlugin < Plugin debug "getting random word from dictionary, matching #{random}" p = @bot.httputil.get(rules[:url] % CGI.escape(random)) debug p + raise 'unable to get search results' if not p.match /Search results for/i lemmi = Array.new good = rules[:good] # We look for a lemma composed by a single word and of length at least two |