From 5f4f233e1789f0ca487a0aa91a9c4abd81d9b18a Mon Sep 17 00:00:00 2001 From: Antti Alasalmi Date: Fri, 26 Feb 2016 12:31:23 +0200 Subject: [PATCH] fixed (?) channel_leave --- bot.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bot.js b/bot.js index 2be394493..6f29e83ae 100755 --- a/bot.js +++ b/bot.js @@ -313,7 +313,7 @@ function formatUptime(uptime) { controller.on('channel_leave',function(bot,message) { controller.storage.users.get(message.user, function(err, user) { - if(user.name!==undefined) { + if(user && user.name) { bot.reply(message,"Ok, " + user.name+", go find a new channel of your own with blackjack and hookers!"); } else {