diff options
author | Sadie Powell <sadie@witchery.services> | 2024-01-08 14:24:13 +0000 |
---|---|---|
committer | Sadie Powell <sadie@witchery.services> | 2024-01-08 14:37:50 +0000 |
commit | f92c5471c24253128939974327eda7db95ff06ee (patch) | |
tree | 4f716467f9ef299db748477448da5d10a4fe4d80 /modules/commands/cs_enforce.cpp | |
parent | 0439e3b21bb197c80974074a614fe3cdf16ddf5a (diff) |
Add a string overload of Channel::Kick.
Diffstat (limited to 'modules/commands/cs_enforce.cpp')
-rw-r--r-- | modules/commands/cs_enforce.cpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/modules/commands/cs_enforce.cpp b/modules/commands/cs_enforce.cpp index d0165013a..248275a01 100644 --- a/modules/commands/cs_enforce.cpp +++ b/modules/commands/cs_enforce.cpp @@ -63,7 +63,7 @@ private: Anope::string mask = ci->GetIdealBan(user); Anope::string reason = Language::Translate(user, _("RESTRICTED enforced by ")) + source.GetNick(); ci->c->SetMode(NULL, "BAN", mask); - ci->c->Kick(NULL, user, "%s", reason.c_str()); + ci->c->Kick(NULL, user, reason); } source.Reply(_("Restricted enforced on %s."), ci->name.c_str()); @@ -92,7 +92,7 @@ private: Anope::string reason = Language::Translate(user, _("REGONLY enforced by ")) + source.GetNick(); if (!ci->c->HasMode("REGISTEREDONLY")) ci->c->SetMode(NULL, "BAN", mask); - ci->c->Kick(NULL, user, "%s", reason.c_str()); + ci->c->Kick(NULL, user, reason); } source.Reply(_("Registered only enforced on %s."), ci->name.c_str()); @@ -121,7 +121,7 @@ private: Anope::string reason = Language::Translate(user, _("SSLONLY enforced by ")) + source.GetNick(); if (!ci->c->HasMode("SSL")) ci->c->SetMode(NULL, "BAN", mask); - ci->c->Kick(NULL, user, "%s", reason.c_str()); + ci->c->Kick(NULL, user, reason); } source.Reply(_("SSL only enforced on %s."), ci->name.c_str()); @@ -147,7 +147,7 @@ private: for (auto *user : users) { Anope::string reason = Language::Translate(user, _("BANS enforced by ")) + source.GetNick(); - ci->c->Kick(NULL, user, "%s", reason.c_str()); + ci->c->Kick(NULL, user, reason); } source.Reply(_("Bans enforced on %s."), ci->name.c_str()); @@ -200,7 +200,7 @@ private: for (auto *user : users) { Anope::string reason = Language::Translate(user, _("LIMIT enforced by ")) + source.GetNick(); - ci->c->Kick(NULL, user, "%s", reason.c_str()); + ci->c->Kick(NULL, user, reason); } source.Reply(_("LIMIT enforced on %s, %zu users removed."), ci->name.c_str(), users.size()); |