drop dead code
--HG-- branch : nmdc-ircfrontend
This commit is contained in:
parent
d2dec97259
commit
e345e8b31e
41
client.go
41
client.go
@ -16,47 +16,6 @@ type Client struct {
|
||||
operator bool
|
||||
}
|
||||
|
||||
/*
|
||||
func (c *Client) joinChannel(channelName string) {
|
||||
newChannel := false
|
||||
|
||||
channelKey := strings.ToLower(channelName)
|
||||
if channelKey != BLESSED_CHANNEL {
|
||||
panic("?")
|
||||
}
|
||||
channel := c.server.channel
|
||||
|
||||
if _, inChannel := channel.clientMap[c.nick]; inChannel {
|
||||
//Client is already in the channel, do nothing
|
||||
return
|
||||
}
|
||||
|
||||
// Transmit the list of joined users to us
|
||||
nicks := make([]string, 0, NICKS_PER_PROTOMSG)
|
||||
|
||||
for _, client := range channel.clientMap {
|
||||
prefix := ""
|
||||
|
||||
if mode, exists := channel.modeMap[client.nick]; exists {
|
||||
prefix = mode.Prefix()
|
||||
}
|
||||
|
||||
if len(nicks) >= cap(nicks) {
|
||||
c.reply(rplNames, channelName, strings.Join(nicks, " "))
|
||||
nicks = nicks[:0]
|
||||
}
|
||||
|
||||
nicks = append(nicks, fmt.Sprintf("%s%s", prefix, client.nick))
|
||||
}
|
||||
|
||||
if len(nicks) > 0 {
|
||||
c.reply(rplNames, channelName, strings.Join(nicks, " "))
|
||||
}
|
||||
|
||||
c.reply(rplEndOfNames, channelName)
|
||||
}
|
||||
*/
|
||||
|
||||
func (c *Client) disconnect() {
|
||||
c.connected = false
|
||||
c.connection.Close()
|
||||
|
Loading…
Reference in New Issue
Block a user