mirror of
https://github.com/ergochat/ergo.git
synced 2024-12-22 02:32:39 +01:00
Um... name monitor subcommands handler properly
This commit is contained in:
parent
b6ba2c7b7a
commit
27c575e191
@ -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"))
|
||||
|
@ -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,
|
||||
|
Loading…
Reference in New Issue
Block a user