]> git.netwichtig.de Git - user/henk/code/ruby/rbot.git/blobdiff - data/rbot/plugins/lastfm.rb
spell plugin: it's spell.path, not spell.program
[user/henk/code/ruby/rbot.git] / data / rbot / plugins / lastfm.rb
index 08a56f8c07df9d7bafad2e43635279f5499861fa..6482b543067ce63c90a1c8e6d0f3ffeadcd40469 100644 (file)
@@ -110,7 +110,7 @@ class LastFmPlugin < Plugin
 
     doc = Document.new xml.body
     if xml.class == Net::HTTPInternalServerError
-      if doc.root.attributes["status"] == "failed"
+      if doc.root and doc.root.attributes["status"] == "failed"
         m.reply doc.root.elements["error"].text
       else
         m.reply _("Could not retrieve events")