From 4b30e65f8305e7fa55be9e0df1e13fc30419bea5 Mon Sep 17 00:00:00 2001 From: Thomas Jager Date: Fri, 31 Jul 2015 07:35:34 +0200 Subject: [PATCH] Fix indentation --- irc_callback.go | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/irc_callback.go b/irc_callback.go index a7576c9..1334d22 100644 --- a/irc_callback.go +++ b/irc_callback.go @@ -161,14 +161,14 @@ func (irc *Connection) setupCallbacks() { irc.AddCallback("CTCP_PING", func(e *Event) { irc.SendRawf("NOTICE %s :\x01%s\x01", e.Nick, e.Message()) }) // 437: ERR_UNAVAILRESOURCE " :Nick/channel is temporarily unavailable" - // Add a _ to current nick. If irc.nickcurrent is empty this cannot - // work. It has to be set somewhere first in case the nick is already - // taken or unavailable from the beginning. - irc.AddCallback("437", func(e *Event) { - // If irc.nickcurrent hasn't been set yet, set to irc.nick - if irc.nickcurrent == "" { - irc.nickcurrent = irc.nick - } + // Add a _ to current nick. If irc.nickcurrent is empty this cannot + // work. It has to be set somewhere first in case the nick is already + // taken or unavailable from the beginning. + irc.AddCallback("437", func(e *Event) { + // If irc.nickcurrent hasn't been set yet, set to irc.nick + if irc.nickcurrent == "" { + irc.nickcurrent = irc.nick + } if len(irc.nickcurrent) > 8 { irc.nickcurrent = "_" + irc.nickcurrent @@ -181,10 +181,10 @@ func (irc *Connection) setupCallbacks() { // 433: ERR_NICKNAMEINUSE " :Nickname is already in use" // Add a _ to current nick. irc.AddCallback("433", func(e *Event) { - // If irc.nickcurrent hasn't been set yet, set to irc.nick - if irc.nickcurrent == "" { - irc.nickcurrent = irc.nick - } + // If irc.nickcurrent hasn't been set yet, set to irc.nick + if irc.nickcurrent == "" { + irc.nickcurrent = irc.nick + } if len(irc.nickcurrent) > 8 { irc.nickcurrent = "_" + irc.nickcurrent