From 1818b19ebaa6584cb97455e1a91e51ecfebd4dfc Mon Sep 17 00:00:00 2001 From: Adam Date: Thu, 12 Sep 2013 22:27:30 -0400 Subject: Fix cs_mode lock reply if nothing is done Fix not clearing forbids when os_forbid is unloaded Apply nick and chan forbids when added Fix loading forbids until after the service is constructed --- modules/commands/cs_mode.cpp | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'modules/commands/cs_mode.cpp') diff --git a/modules/commands/cs_mode.cpp b/modules/commands/cs_mode.cpp index f7233eb27..1cd3f7a08 100644 --- a/modules/commands/cs_mode.cpp +++ b/modules/commands/cs_mode.cpp @@ -353,8 +353,11 @@ class CommandCSMode : public Command neg.clear(); Anope::string reply = pos + neg + pos_params + neg_params; - source.Reply(_("%s locked on %s."), reply.c_str(), ci->name.c_str()); - Log(override ? LOG_OVERRIDE : LOG_COMMAND, source, this, ci) << "to lock " << reply; + if (!reply.empty()) + { + source.Reply(_("%s locked on %s."), reply.c_str(), ci->name.c_str()); + Log(override ? LOG_OVERRIDE : LOG_COMMAND, source, this, ci) << "to lock " << reply; + } if (ci->c) ci->c->CheckModes(); -- cgit