summaryrefslogtreecommitdiff
path: root/modules/extra
diff options
context:
space:
mode:
Diffstat (limited to 'modules/extra')
-rw-r--r--modules/extra/cs_set_misc.cpp3
-rw-r--r--modules/extra/ns_set_misc.cpp3
2 files changed, 4 insertions, 2 deletions
diff --git a/modules/extra/cs_set_misc.cpp b/modules/extra/cs_set_misc.cpp
index 7cffe6866..d287a24c1 100644
--- a/modules/extra/cs_set_misc.cpp
+++ b/modules/extra/cs_set_misc.cpp
@@ -23,7 +23,8 @@ class CommandCSSetMisc : public Command
CommandReturn Execute(User *u, const std::vector<Anope::string> &params)
{
ChannelInfo *ci = cs_findchan(params[0]);
- assert(ci);
+ if (!ci)
+ throw CoreException("NULL ci in CommandCSSetMisc");
ci->Shrink("chanserv:" + this->name);
if (params.size() > 1)
diff --git a/modules/extra/ns_set_misc.cpp b/modules/extra/ns_set_misc.cpp
index 9e0f23eb0..8ab54fd05 100644
--- a/modules/extra/ns_set_misc.cpp
+++ b/modules/extra/ns_set_misc.cpp
@@ -22,7 +22,8 @@ class CommandNSSetMisc : public Command
CommandReturn RealExecute(User *u, const std::vector<Anope::string> &params)
{
NickCore *nc = findcore(params[0]);
- assert(nc);
+ if (!nc)
+ throw CoreException("NULL nc in CommandNSSetMisc");
nc->Shrink("nickserv:" + this->name);
if (params.size() > 1)