logger: Very initial working new logs

This commit is contained in:
Daniel Oaks 2017-03-06 15:50:23 +10:00
parent 45dd882ec4
commit 29e89b16a0
5 changed files with 51 additions and 33 deletions

View file

@ -402,7 +402,7 @@ func (client *Client) AllNickmasks() []string {
// SetNickname sets the very first nickname for the client.
func (client *Client) SetNickname(nickname string) error {
if client.HasNick() {
Log.error.Printf("%s nickname already set!", client.nickMaskString)
client.server.logger.Log(LogError, "nick", client.nick, fmt.Sprintf("%s nickname already set, something is wrong with server consistency", client.nickMaskString))
return ErrNickAlreadySet
}
@ -543,7 +543,7 @@ var (
"NOTICE": true,
RPL_WHOISCHANNELS: true,
RPL_USERHOST: true,
RPL_USERHOST: true,
}
)