]> git.netwichtig.de Git - user/henk/code/ruby/rbot.git/blobdiff - data/rbot/plugins/grouphug.rb
+ (rss.rb) monkey-patch some basic common api over different rss item impls
[user/henk/code/ruby/rbot.git] / data / rbot / plugins / grouphug.rb
index 889c4746e6a5d57c076c0c43cb63ca05243e648e..90527fb7f61db1cd75bc67bfd98fc614daf58249 100644 (file)
@@ -18,7 +18,7 @@ class GrouphugPlugin < Plugin
   end
 
   def help( plugin, topic="" )
-    return _("Grouphug plugin. Confess! Usage: 'confess' for random confession, 'confess <number>' for specific one, 'confess <confession>' to share your own confession, but you must have create auth. Confessions must be at least 10 words.")
+    return _("Grouphug plugin. Confess! Usage: 'confess' for random confession, 'confess <number>' for specific one, 'confess <confession>' to share your own confession. Confessions must be at least 10 words.")
   end
 
   def post_confession(m, params)
@@ -57,7 +57,7 @@ class GrouphugPlugin < Plugin
         data = @bot.httputil.get("http://grouphug.us/#{path}", opts)
 
         res = data.scan(REG)
-        confession = res[0][0].ircify_html
+        confession = res[2][0].ircify_html # use res[2] to skip the new sidebar "Group Hug is run by one person..." and other text.
         confession = "no confession ##{params[:num]} found" if confession.empty? and params[:num]
         m.reply confession
       else # Cache random confessions