]> git.netwichtig.de Git - user/henk/code/ruby/rbot.git/commitdiff
note: dup the keys, not the registry
authorGiuseppe Bilotta <giuseppe.bilotta@gmail.com>
Mon, 29 Apr 2013 05:37:28 +0000 (07:37 +0200)
committerGiuseppe Bilotta <giuseppe.bilotta@gmail.com>
Mon, 29 Apr 2013 05:37:28 +0000 (07:37 +0200)
data/rbot/plugins/note.rb

index 59e1e6a0a175adbcc39a318c66fada8e850d86a6..e0a7be293a05a192375e4aed7e03cebe72ad347c 100644 (file)
@@ -21,7 +21,7 @@ class NotePlugin < Plugin
     return if @registry.length < 1
     debug 'Checking registry for old-formatted notes...'
     n = 0
-    @registry.dup.each_key do |key|
+    @registry.keys.each do |key|
       unless key == key.downcase
         @registry[key.downcase] = @registry[key] + (@registry[key.downcase] || [])
         @registry.delete key