From 5418e5e7943c92508c27e04ab9b695cff32210c6 Mon Sep 17 00:00:00 2001 From: Shivaram Lingamneni Date: Tue, 27 Oct 2020 18:54:45 -0400 Subject: [PATCH] fix #769 Add 379 RPL_WHOISMODES --- irc/numerics.go | 1 + irc/server.go | 1 + 2 files changed, 2 insertions(+) diff --git a/irc/numerics.go b/irc/numerics.go index 951653df..9aa09bab 100644 --- a/irc/numerics.go +++ b/irc/numerics.go @@ -98,6 +98,7 @@ const ( RPL_ENDOFINFO = "374" RPL_MOTDSTART = "375" RPL_ENDOFMOTD = "376" + RPL_WHOISMODES = "379" RPL_YOUREOPER = "381" RPL_REHASHING = "382" RPL_YOURESERVICE = "383" diff --git a/irc/server.go b/irc/server.go index f92f0de1..3676293d 100644 --- a/irc/server.go +++ b/irc/server.go @@ -450,6 +450,7 @@ func (client *Client) getWhoisOf(target *Client, hasPrivs bool, rb *ResponseBuff } if client == target || hasPrivs { rb.Add(nil, client.server.name, RPL_WHOISACTUALLY, cnick, tnick, fmt.Sprintf("%s@%s", targetInfo.username, target.RawHostname()), target.IPString(), client.t("Actual user@host, Actual IP")) + rb.Add(nil, client.server.name, RPL_WHOISMODES, cnick, tnick, fmt.Sprintf(client.t("is using modes +%s"), target.modes.String())) } if target.HasMode(modes.TLS) { rb.Add(nil, client.server.name, RPL_WHOISSECURE, cnick, tnick, client.t("is using a secure connection"))