]> git.netwichtig.de Git - user/henk/code/ruby/rbot.git/blobdiff - data/rbot/plugins/slashdot.rb
spell plugin: command line option
[user/henk/code/ruby/rbot.git] / data / rbot / plugins / slashdot.rb
index 657cc0099b39c26f6c1ea263db3e2478b2c6de1b..71411458e7300565cd1b069d240b1e39ade44953 100644 (file)
@@ -23,8 +23,9 @@ class SlashdotPlugin < Plugin
     h = Hpricot(s[:text])
     # If we have no title tag in a head tag, return as this is not
     # a /. page (it's probably a Slashdot RSS
-    return nil if h/"head/title".empty?
-    title = (h/"head/title").first.to_html.ircify_html
+    ht = h/"head/title"
+    return nil if ht.empty?
+    title = ht.first.to_html.ircify_html
     arts = (h/"div.article")
     return nil if arts.empty?
     if arts.length > 1