3
0
mirror of https://github.com/ergochat/ergo.git synced 2024-11-11 06:29:29 +01:00

Merge pull request #1362 from slingamn/issue769_rplwhoismodes

fix #769
This commit is contained in:
Shivaram Lingamneni 2020-10-28 08:06:39 -07:00 committed by GitHub
commit 6cd6da600a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 0 deletions

View File

@ -98,6 +98,7 @@ const (
RPL_ENDOFINFO = "374" RPL_ENDOFINFO = "374"
RPL_MOTDSTART = "375" RPL_MOTDSTART = "375"
RPL_ENDOFMOTD = "376" RPL_ENDOFMOTD = "376"
RPL_WHOISMODES = "379"
RPL_YOUREOPER = "381" RPL_YOUREOPER = "381"
RPL_REHASHING = "382" RPL_REHASHING = "382"
RPL_YOURESERVICE = "383" RPL_YOURESERVICE = "383"

View File

@ -450,6 +450,7 @@ func (client *Client) getWhoisOf(target *Client, hasPrivs bool, rb *ResponseBuff
} }
if client == target || hasPrivs { 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_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) { if target.HasMode(modes.TLS) {
rb.Add(nil, client.server.name, RPL_WHOISSECURE, cnick, tnick, client.t("is using a secure connection")) rb.Add(nil, client.server.name, RPL_WHOISSECURE, cnick, tnick, client.t("is using a secure connection"))