summaryrefslogtreecommitdiff
path: root/src/modules/m_spanningtree
diff options
context:
space:
mode:
Diffstat (limited to 'src/modules/m_spanningtree')
-rw-r--r--src/modules/m_spanningtree/postcommand.cpp14
1 files changed, 7 insertions, 7 deletions
diff --git a/src/modules/m_spanningtree/postcommand.cpp b/src/modules/m_spanningtree/postcommand.cpp
index 6afe8e2c9..b08f60925 100644
--- a/src/modules/m_spanningtree/postcommand.cpp
+++ b/src/modules/m_spanningtree/postcommand.cpp
@@ -52,15 +52,15 @@ void SpanningTreeUtilities::RouteCommand(TreeServer* origin, const std::string &
if (routing.type == ROUTE_TYPE_LOCALONLY)
{
- Module* srcmodule = thiscmd->creator;
- Version ver = srcmodule->GetVersion();
+ /* Broadcast when it's a core command with the default route descriptor and the source is a
+ * remote user or a remote server
+ */
- if ((ver.Flags & VF_CORE) && !IS_LOCAL(user))
- routing = ROUTE_BROADCAST;
- else
- return;
- if (IS_SERVER(user) && user != ServerInstance->FakeClient)
+ Version ver = thiscmd->creator->GetVersion();
+ if ((!(ver.Flags & VF_CORE)) || (IS_LOCAL(user)) || (IS_SERVER(user) == ServerInstance->FakeClient))
return;
+
+ routing = ROUTE_BROADCAST;
}
else if (routing.type == ROUTE_TYPE_OPT_BCAST)
{