diff options
author | brain <brain@e03df62e-2008-0410-955e-edbf42e46eb7> | 2005-12-04 21:14:13 +0000 |
---|---|---|
committer | brain <brain@e03df62e-2008-0410-955e-edbf42e46eb7> | 2005-12-04 21:14:13 +0000 |
commit | 6a997236cf5ed6bc5aaa0263183b1c90ec2e7191 (patch) | |
tree | a839c7bfcab42ba18850bc1c2d7b9744f93d43eb /src/modules | |
parent | 068fa624940d287c9d0f8797c0c385a1390aba35 (diff) |
Fixed to not break with m_spanningtree
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@2174 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'src/modules')
-rw-r--r-- | src/modules/m_conn_lusers.cpp | 16 |
1 files changed, 15 insertions, 1 deletions
diff --git a/src/modules/m_conn_lusers.cpp b/src/modules/m_conn_lusers.cpp index c0106566a..7bf2013e1 100644 --- a/src/modules/m_conn_lusers.cpp +++ b/src/modules/m_conn_lusers.cpp @@ -49,7 +49,21 @@ class ModuleConnLUSERS : public Module virtual void OnUserConnect(userrec* user) { - Srv->CallCommandHandler("LUSERS", NULL, 0, user); + // if we're using a protocol module, we cant just call + // the command handler because the protocol module + // has hooked it. We must call OnPreCommand in the + // protocol module. Yes, at some point there will + // be a way to get the current protocol module's name + // from the core and probably a pointer to its class. + Module* Proto = FindModule("m_spanningtree.so"); + if (Proto) + { + Proto->OnPreCommand("LUSERS", NULL, 0, user) + } + else + { + Srv->CallCommandHandler("LUSERS", NULL, 0, user); + } } }; |