summaryrefslogtreecommitdiff
path: root/src/core/hs_set.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/core/hs_set.c')
-rw-r--r--src/core/hs_set.c12
1 files changed, 7 insertions, 5 deletions
diff --git a/src/core/hs_set.c b/src/core/hs_set.c
index fd66ca911..a117f7540 100644
--- a/src/core/hs_set.c
+++ b/src/core/hs_set.c
@@ -26,6 +26,12 @@ class CommandHSSet : public Command
CommandReturn Execute(User *u, std::vector<std::string> &params)
{
+ if (!u->nc->HasPriv("hostserv/set"))
+ {
+ notice_lang(s_HostServ, u, ACCESS_DENIED);
+ return MOD_CONT;
+ }
+
const char *nick = params[0].c_str();
const char *rawhostmask = params[1].c_str();
char *hostmask = new char[HOSTMAX];
@@ -143,9 +149,6 @@ class CommandHSSet : public Command
bool OnHelp(User *u, const std::string &subcommand)
{
- if (!is_host_setter(u))
- return false;
-
notice_help(s_HostServ, u, HOST_HELP_SET);
return true;
}
@@ -177,8 +180,7 @@ class HSSet : public Module
**/
void myHostServHelp(User *u)
{
- if (is_host_setter(u))
- notice_lang(s_HostServ, u, HOST_HELP_CMD_SET);
+ notice_lang(s_HostServ, u, HOST_HELP_CMD_SET);
}
MODULE_INIT("hs_set", HSSet)