diff options
author | Robby- <robby@chat.be> | 2014-03-19 03:01:09 +0100 |
---|---|---|
committer | Robby- <robby@chat.be> | 2014-03-19 03:05:54 +0100 |
commit | 4f412bc213a064346bc2d3ec3d6cf41a4c82ec58 (patch) | |
tree | b9d380fecc822b459717f5d6d5c9375466083672 | |
parent | 1882916dc421eab1d55ba629d6dd6beb4a271787 (diff) |
cs_set_misc: Add missing override capability for services operators, and logging.
-rw-r--r-- | modules/commands/cs_set_misc.cpp | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/modules/commands/cs_set_misc.cpp b/modules/commands/cs_set_misc.cpp index 2c51b58b7..3457bbed3 100644 --- a/modules/commands/cs_set_misc.cpp +++ b/modules/commands/cs_set_misc.cpp @@ -116,7 +116,7 @@ class CommandCSSetMisc : public Command if (MOD_RESULT == EVENT_STOP) return; - if (MOD_RESULT != EVENT_ALLOW && source.permission.empty() && !source.AccessFor(ci).HasPriv("SET")) + if (MOD_RESULT != EVENT_ALLOW && !source.AccessFor(ci).HasPriv("SET") && source.permission.empty() && !source.HasPriv("chanserv/administration")) { source.Reply(ACCESS_DENIED); return; @@ -131,11 +131,13 @@ class CommandCSSetMisc : public Command if (!param.empty()) { item->Set(ci, CSMiscData(ci, key, param)); + Log(source.AccessFor(ci).HasPriv("SET") ? LOG_COMMAND : LOG_OVERRIDE, source, this, ci) << "to change it to " << param; source.Reply(CHAN_SETTING_CHANGED, scommand.c_str(), ci->name.c_str(), params[1].c_str()); } else { item->Unset(ci); + Log(source.AccessFor(ci).HasPriv("SET") ? LOG_COMMAND : LOG_OVERRIDE, source, this, ci) << "to unset it"; source.Reply(CHAN_SETTING_UNSET, scommand.c_str(), ci->name.c_str()); } } |