summaryrefslogtreecommitdiff
path: root/modules/nickserv/info.cpp
diff options
context:
space:
mode:
authorAdam <Adam@anope.org>2016-10-09 19:51:39 -0400
committerAdam <Adam@anope.org>2016-10-09 19:51:39 -0400
commite7dd7159b1e1ab5b3edabc44ece5338672f8fbb4 (patch)
tree9517f02ca1c29fa247f6914398f35a44052c22ff /modules/nickserv/info.cpp
parent8ceca4fd3f9cb82bc93801d5eb682d27b2ad2f54 (diff)
Make vhosts assignable to accounts, not nicks. Allow multiple vhosts per account.
Diffstat (limited to 'modules/nickserv/info.cpp')
-rw-r--r--modules/nickserv/info.cpp18
1 files changed, 7 insertions, 11 deletions
diff --git a/modules/nickserv/info.cpp b/modules/nickserv/info.cpp
index e782edbaa..447554afb 100644
--- a/modules/nickserv/info.cpp
+++ b/modules/nickserv/info.cpp
@@ -107,15 +107,11 @@ class CommandNSInfo : public Command
if (!na->GetAccount()->GetEmail().empty() && (show_hidden || !na->GetAccount()->HasFieldS("HIDE_EMAIL")))
info[_("Email address")] = na->GetAccount()->GetEmail();
- if (show_hidden)
+ if (source.HasPriv("hostserv/auspex"))
{
- HostServ::VHost *vhost = na->GetVHost();
- if (vhost != nullptr)
+ for (HostServ::VHost *vhost : na->GetAccount()->GetRefs<HostServ::VHost *>())
{
- if (IRCD->CanSetVIdent && !vhost->GetIdent().empty())
- info[_("VHost")] = vhost->GetIdent() + "@" + vhost->GetHost();
- else
- info[_("VHost")] = vhost->GetHost();
+ info[_("VHost")] = vhost->Mask() + (vhost->IsDefault() ? " (default)" : "");
}
}
@@ -132,10 +128,10 @@ class CommandNSInfo : public Command
{
this->SendSyntax(source);
source.Reply(" ");
- source.Reply(_("Displays information about the given nickname, such as\n"
- "the nick's owner, last seen address and time, and nick\n"
- "options. If no nick is given, and you are identified,\n"
- "your account name is used, else your current nickname is\n"
+ source.Reply(_("Displays information about the given nickname, such as "
+ "the nick's owner, last seen address and time, and nick "
+ "options. If no nick is given, and you are identified, "
+ "your account name is used, else your current nickname is "
"used."));
return true;