Browse Source

fix UBAN INFO considering the wrong IP

tags/v2.5.0-rc1
Shivaram Lingamneni 3 years ago
parent
commit
6bd396f5a2
1 changed files with 2 additions and 2 deletions
  1. 2
    2
      irc/uban.go

+ 2
- 2
irc/uban.go View File

@@ -365,10 +365,10 @@ func ubanInfoNick(client *Client, target ubanTarget, rb *ResponseBuffer) {
365 365
 	if mcl != nil {
366 366
 		details := mcl.Details()
367 367
 		if details.account == "" {
368
-			rb.Notice(fmt.Sprintf(client.t("Client %[1]s is unauthenticated and connected from %[2]s"), details.nick, client.IP().String()))
368
+			rb.Notice(fmt.Sprintf(client.t("Client %[1]s is unauthenticated and connected from %[2]s"), details.nick, mcl.IP().String()))
369 369
 		} else {
370 370
 			rb.Notice(fmt.Sprintf(client.t("Client %[1]s is logged into account %[2]s and has %[3]d active clients (see /NICKSERV CLIENTS LIST %[4]s for more info"), details.nick, details.accountName, len(mcl.Sessions()), details.nick))
371
-			ip := client.IP()
371
+			ip := mcl.IP()
372 372
 			if !ip.IsLoopback() {
373 373
 				rb.Notice(fmt.Sprintf(client.t("Client %[1]s is associated with IP %[2]s; you can ban this IP with /UBAN ADD"), details.nick, ip.String()))
374 374
 			}

Loading…
Cancel
Save