diff options
author | Sadie Powell <sadie@witchery.services> | 2020-08-01 08:28:10 +0100 |
---|---|---|
committer | Sadie Powell <sadie@witchery.services> | 2020-08-01 08:28:30 +0100 |
commit | eb11cc14db861ac8bfe6b93515272a8ab11fb714 (patch) | |
tree | 9c40fec1655139f37f0c546b6e930533a617ed28 /src/modules | |
parent | 279ad1616d0d30c6a026d8fa5c573e20b6af9699 (diff) |
Fix null-checking the wrong variable in the disable module.
Closes #1792.
Diffstat (limited to 'src/modules')
-rw-r--r-- | src/modules/m_disable.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/modules/m_disable.cpp b/src/modules/m_disable.cpp index 9f08cc6b3..95fcd8b4c 100644 --- a/src/modules/m_disable.cpp +++ b/src/modules/m_disable.cpp @@ -55,7 +55,7 @@ class ModuleDisable : public Module // Check that the mode actually exists. ModeHandler* mh = ServerInstance->Modes->FindMode(chr, type); - if (!chr) + if (!mh) throw ModuleException(InspIRCd::Format("Nonexistent mode '%c' was specified in <disabled:%s> at %s", chr, field.c_str(), tag->getTagLocation().c_str())); |