summaryrefslogtreecommitdiff
path: root/modules/commands/cs_access.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'modules/commands/cs_access.cpp')
-rw-r--r--modules/commands/cs_access.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/modules/commands/cs_access.cpp b/modules/commands/cs_access.cpp
index ae4a291a0..6f1f0f1f0 100644
--- a/modules/commands/cs_access.cpp
+++ b/modules/commands/cs_access.cpp
@@ -162,6 +162,7 @@ class CommandCSAccess : public Command
else
{
na = NickServ::FindNick(mask);
+
if (!na && Config->GetModule("chanserv")->Get<bool>("disallow_hostmask_access"))
{
source.Reply(_("Masks and unregistered users may not be on access lists."));
@@ -179,6 +180,9 @@ class CommandCSAccess : public Command
return;
}
}
+
+ if (na)
+ mask = na->GetNick();
}
for (unsigned i = ci->GetAccessCount(); i > 0; --i)
@@ -502,6 +506,8 @@ class CommandCSAccess : public Command
bool has_access = false;
if (source.HasPriv("chanserv/access/modify"))
has_access = true;
+ else if (is_list && source.HasPriv("chanserv/access/list"))
+ has_access = true;
else if (is_list && source.AccessFor(ci).HasPriv("ACCESS_LIST"))
has_access = true;
else if (source.AccessFor(ci).HasPriv("ACCESS_CHANGE"))