summaryrefslogtreecommitdiff
path: root/modules/commands/ns_info.cpp
diff options
context:
space:
mode:
authorAdam <Adam@anope.org>2013-12-24 18:19:44 -0500
committerAdam <Adam@anope.org>2013-12-24 18:19:44 -0500
commit421e194c5a19a35a913f9509da0d194f835555a6 (patch)
treeda9e8f3ebe9008f73b992d57139aff9a95cb5b90 /modules/commands/ns_info.cpp
parentc442bc18afefff6661b1108a4980e2a4f3c8e36d (diff)
If last usermask and last realhost are the same, don't show both because duh
Diffstat (limited to 'modules/commands/ns_info.cpp')
-rw-r--r--modules/commands/ns_info.cpp7
1 files changed, 6 insertions, 1 deletions
diff --git a/modules/commands/ns_info.cpp b/modules/commands/ns_info.cpp
index b74e84763..21e0fab5d 100644
--- a/modules/commands/ns_info.cpp
+++ b/modules/commands/ns_info.cpp
@@ -71,9 +71,14 @@ class CommandNSInfo : public Command
}
else
{
+ Anope::string shown;
if (show_hidden || !na->nc->HasExt("HIDE_MASK"))
+ {
info[_("Last seen address")] = na->last_usermask;
- if (show_hidden && !na->last_realhost.empty())
+ shown = na->last_usermask;
+ }
+
+ if (show_hidden && !na->last_realhost.empty() && na->last_realhost != shown)
info[_("Last seen address")] = na->last_realhost;
}