]> git.netwichtig.de Git - user/henk/code/ruby/rbot.git/blobdiff - data/rbot/plugins/quotes.rb
Bug in topic plugin introduced in [440]
[user/henk/code/ruby/rbot.git] / data / rbot / plugins / quotes.rb
index b795af531619e12e67e1d9839bc2afbd2315cf25..390b98f7077aa6753ef7a4e5013baeef2cf17fb0 100644 (file)
@@ -1,6 +1,6 @@
 # GB: Ok, we *really* need to switch to db for this plugin too
 
-Quote = Struct.new("Quote", "num", "date", "source", "quote")
+Quote = Struct.new("Quote", :num, :date, :source, :quote)
 
 class QuotePlugin < Plugin
   def initialize
@@ -33,9 +33,9 @@ class QuotePlugin < Plugin
         File.rename("#{@bot.botclass}/quotes/new/#{channel}",
                     "#{@bot.botclass}/quotes/#{channel}")
       rescue => e
-        $stderr.puts "failed to write quotefile for channel #{channel}!\n#{$!}"
-        debug "#{e.class}: #{e}"
-        debug e.backtrace.join("\n")
+        error "failed to write quotefile for channel #{channel}!\n#{$!}"
+        error "#{e.class}: #{e}"
+        error e.backtrace.join("\n")
       end
     }
   end