diff options
| author | 2021-12-14 15:48:57 +0000 | |
|---|---|---|
| committer | 2021-12-14 15:48:57 +0000 | |
| commit | 64340dc50901f88336d9a2933dad98b462b6f36b (patch) | |
| tree | e3512ff37a0ae8dd1b2c87a54382e6cf5325f49f /src/modules/m_spanningtree/main.cpp | |
| parent | Add a build time check that OpenLDAP is reentrant. (diff) | |
Sync uniqueusername from the connect class to the user.
This is a massive hack for now but should be made to sync properly
in v4 when we have extensibles that don't suck.
Diffstat (limited to 'src/modules/m_spanningtree/main.cpp')
| -rw-r--r-- | src/modules/m_spanningtree/main.cpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/modules/m_spanningtree/main.cpp b/src/modules/m_spanningtree/main.cpp index c829b31d3..5e30469e9 100644 --- a/src/modules/m_spanningtree/main.cpp +++ b/src/modules/m_spanningtree/main.cpp @@ -803,6 +803,14 @@ void ModuleSpanningTree::OnShutdown(const std::string& reason) children.front()->SQuit(reason, true); } +void ModuleSpanningTree::OnDecodeMetaData(Extensible* target, const std::string& extname, const std::string& extdata) +{ + // HACK: this should use automatically synced user metadata in v4. + User* dest = static_cast<User*>(target); + if (dest && (extname == "uniqueusername")) + dest->uniqueusername = true; +} + CullResult ModuleSpanningTree::cull() { if (Utils) |
