From c181583f3903a9f7d639ccc917ecf7241bf892a3 Mon Sep 17 00:00:00 2001 From: Sebastian Wicki Date: Mon, 7 Nov 2011 20:15:18 +0100 Subject: [PATCH] Accept server-assigned nickname --- handlers.lua | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/handlers.lua b/handlers.lua index 2919a49..39d6777 100644 --- a/handlers.lua +++ b/handlers.lua @@ -10,8 +10,9 @@ handlers["PING"] = function(o, prefix, query) o:send("PONG :%s", query) end -handlers["001"] = function(o) +handlers["001"] = function(o, prefix, me) o.authed = true + o.nick = me end handlers["PRIVMSG"] = function(o, prefix, channel, message)