summaryrefslogtreecommitdiff
path: root/src/modules
diff options
context:
space:
mode:
Diffstat (limited to 'src/modules')
-rw-r--r--src/modules/m_chanprotect.cpp12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/modules/m_chanprotect.cpp b/src/modules/m_chanprotect.cpp
index 872ff8d7c..caef4961f 100644
--- a/src/modules/m_chanprotect.cpp
+++ b/src/modules/m_chanprotect.cpp
@@ -261,14 +261,14 @@ class ModuleChanProtect : public Module
if ((APrefix && QPrefix) && APrefix == QPrefix)
throw ModuleException("What the smeg, why are both your +q and +a prefixes the same character?");
- if (ServerInstance->Modes->FindPrefix(APrefix) && ServerInstance->Modes->FindPrefix(APrefix) != &cp)
- throw ModuleException("Looks like the +a prefix you picked for m_chanprotect is already in use. Pick another.");
-
- if (ServerInstance->Modes->FindPrefix(QPrefix) && ServerInstance->Modes->FindPrefix(QPrefix) != &cf)
- throw ModuleException("Looks like the +q prefix you picked for m_chanprotect is already in use. Pick another.");
-
if (settings.booting)
{
+ if (APrefix && ServerInstance->Modes->FindPrefix(APrefix) && ServerInstance->Modes->FindPrefix(APrefix) != &cp)
+ throw ModuleException("Looks like the +a prefix you picked for m_chanprotect is already in use. Pick another.");
+
+ if (QPrefix && ServerInstance->Modes->FindPrefix(QPrefix) && ServerInstance->Modes->FindPrefix(QPrefix) != &cf)
+ throw ModuleException("Looks like the +q prefix you picked for m_chanprotect is already in use. Pick another.");
+
cp.setPrefix(APrefix);
cf.setPrefix(QPrefix);
}