aboutsummaryrefslogtreecommitdiff
path: root/src/modules/m_spanningtree
diff options
context:
space:
mode:
authorGravatar Sadie Powell2021-12-03 13:37:42 +0000
committerGravatar Sadie Powell2021-12-03 13:37:42 +0000
commit2466c048e26c09461b4ced2a9dfcf6d87f0e1323 (patch)
treea4575894c6945acef81eb3dd91a206879dbec2ac /src/modules/m_spanningtree
parentFix a bunch of cases where module types were not marked as final. (diff)
Consistently use `!foo` instead of `foo == NULL`.
Diffstat (limited to 'src/modules/m_spanningtree')
-rw-r--r--src/modules/m_spanningtree/fjoin.cpp2
-rw-r--r--src/modules/m_spanningtree/treeserver.h2
2 files changed, 2 insertions, 2 deletions
diff --git a/src/modules/m_spanningtree/fjoin.cpp b/src/modules/m_spanningtree/fjoin.cpp
index c945240f1..bc7595eb6 100644
--- a/src/modules/m_spanningtree/fjoin.cpp
+++ b/src/modules/m_spanningtree/fjoin.cpp
@@ -153,7 +153,7 @@ CmdResult CommandFJoin::Handle(User* srcuser, Params& params)
// XXX: If the channel does not exist in the chan hash at this point, create it so the remote modes can be applied on it.
// This happens to 0-user permanent channels on the losing side, because those are removed (from the chan hash, then
// deleted later) as soon as the permchan mode is removed from them.
- if (ServerInstance->Channels.Find(channel) == NULL)
+ if (!ServerInstance->Channels.Find(channel))
{
chan = new Channel(channel, TS);
}
diff --git a/src/modules/m_spanningtree/treeserver.h b/src/modules/m_spanningtree/treeserver.h
index 82aaa1f3c..966dbf9d1 100644
--- a/src/modules/m_spanningtree/treeserver.h
+++ b/src/modules/m_spanningtree/treeserver.h
@@ -132,7 +132,7 @@ class TreeServer final
/** Returns true if this server is the tree root (i.e.: us)
*/
- bool IsRoot() const { return (this->Parent == NULL); }
+ bool IsRoot() const { return (!this->Parent); }
/** Returns true if this server is locally connected
*/