diff options
author | danieldg <danieldg@e03df62e-2008-0410-955e-edbf42e46eb7> | 2010-02-24 18:49:21 +0000 |
---|---|---|
committer | danieldg <danieldg@e03df62e-2008-0410-955e-edbf42e46eb7> | 2010-02-24 18:49:21 +0000 |
commit | 051749fa68a78e5a6e808f2a7d151788c75f9373 (patch) | |
tree | 4a7c729a6c319e58d3540efa99db39f8db5e7711 /src | |
parent | f1c4050e04dc386f2aa4351bfd34677ec554661b (diff) |
Fix empty prefixes in m_chanprotect
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@12558 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'src')
-rw-r--r-- | src/modules/m_chanprotect.cpp | 12 |
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); } |