diff options
author | Giuseppe Bilotta <giuseppe.bilotta@gmail.com> | 2008-02-15 00:40:05 +0100 |
---|---|---|
committer | Giuseppe Bilotta <giuseppe.bilotta@gmail.com> | 2008-02-15 00:40:05 +0100 |
commit | 82e5e233ddb878a22a056439dc2f5b40ddf7312e (patch) | |
tree | d5f6bd0ed7984d2c92eaf477d110072d93817fa2 | |
parent | 6597d0ddca268bada27cb5d7750a3fcce89dd658 (diff) |
bash plugin: check if the html is actually there
-rw-r--r-- | data/rbot/plugins/bash.rb | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/data/rbot/plugins/bash.rb b/data/rbot/plugins/bash.rb index 0524204a..6c12ce5e 100644 --- a/data/rbot/plugins/bash.rb +++ b/data/rbot/plugins/bash.rb @@ -98,6 +98,11 @@ class BashPlugin < Plugin end end + if not html + m.reply "unable to retrieve quotes" + return + end + html_quotes = html.split(/<p class="quote">/) html_quotes.each { |htqt| # debug htqt.inspect |