From: Giuseppe Bilotta Date: Sun, 28 Apr 2013 06:54:03 +0000 (+0200) Subject: note: if is more readale than unless here X-Git-Url: https://git.netwichtig.de/gitweb/?a=commitdiff_plain;h=095a126c82c0fc886b15296942588aabbf49b4f6;p=user%2Fhenk%2Fcode%2Fruby%2Frbot.git note: if is more readale than unless here --- diff --git a/data/rbot/plugins/note.rb b/data/rbot/plugins/note.rb index 8dfae361..59e1e6a0 100644 --- a/data/rbot/plugins/note.rb +++ b/data/rbot/plugins/note.rb @@ -45,10 +45,10 @@ class NotePlugin < Plugin priv = [] @registry[nick].each do |n| s = "[#{n.time.strftime('%b-%e %H:%M')}] <#{n.from}> #{n.text}" - unless n.private or @bot.config['note.private_message'] - pub << s - else + if n.private or @bot.config['note.private_message'] priv << s + else + pub << s end end unless pub.empty?