3
0
mirror of https://github.com/ergochat/ergo.git synced 2024-11-22 03:49:27 +01:00

Um... name monitor subcommands handler properly

This commit is contained in:
Daniel Oaks 2018-04-12 10:11:45 +10:00
parent b6ba2c7b7a
commit 27c575e191
2 changed files with 2 additions and 2 deletions

View File

@ -1445,7 +1445,7 @@ func umodeHandler(server *Server, client *Client, msg ircmsg.IrcMessage, rb *Res
// MONITOR <subcmd> [params...]
func monitorHandler(server *Server, client *Client, msg ircmsg.IrcMessage, rb *ResponseBuffer) bool {
handler, exists := metadataSubcommands[strings.ToLower(msg.Params[0])]
handler, exists := monitorSubcommands[strings.ToLower(msg.Params[0])]
if !exists {
rb.Add(nil, server.name, ERR_UNKNOWNERROR, client.Nick(), "MONITOR", msg.Params[0], client.t("Unknown subcommand"))

View File

@ -103,7 +103,7 @@ func (manager *MonitorManager) List(client *Client) (nicks []string) {
}
var (
metadataSubcommands = map[string]func(server *Server, client *Client, msg ircmsg.IrcMessage, rb *ResponseBuffer) bool{
monitorSubcommands = map[string]func(server *Server, client *Client, msg ircmsg.IrcMessage, rb *ResponseBuffer) bool{
"-": monitorRemoveHandler,
"+": monitorAddHandler,
"c": monitorClearHandler,