summaryrefslogtreecommitdiff
path: root/modules/commands/cs_set_persist.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'modules/commands/cs_set_persist.cpp')
-rw-r--r--modules/commands/cs_set_persist.cpp3
1 files changed, 1 insertions, 2 deletions
diff --git a/modules/commands/cs_set_persist.cpp b/modules/commands/cs_set_persist.cpp
index 60cc7895d..fbca0994f 100644
--- a/modules/commands/cs_set_persist.cpp
+++ b/modules/commands/cs_set_persist.cpp
@@ -24,7 +24,6 @@ class CommandCSSetPersist : public Command
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
{
- User *u = source.u;
ChannelInfo *ci = cs_findchan(params[0]);
if (ci == NULL)
{
@@ -32,7 +31,7 @@ class CommandCSSetPersist : public Command
return;
}
- if (source.permission.empty() && !ci->AccessFor(u).HasPriv("SET"))
+ if (source.permission.empty() && !source.AccessFor(ci).HasPriv("SET"))
{
source.Reply(ACCESS_DENIED);
return;