]> git.netwichtig.de Git - user/henk/code/inspircd.git/blobdiff - src/channels.cpp
m_spanningtree Send the cert fingerprint message to opers only after successful auth
[user/henk/code/inspircd.git] / src / channels.cpp
index 77b7f81db21281f835f104fce93bcfec68e1a230..f49d359cd27f778c4a599948e51265ee05a7d0ea 100644 (file)
@@ -25,8 +25,6 @@
 
 #include "inspircd.h"
 #include "listmode.h"
-#include <cstdarg>
-#include "mode.h"
 
 namespace
 {
@@ -292,17 +290,17 @@ Channel* Channel::JoinUser(LocalUser* user, std::string cname, bool override, co
        return chan;
 }
 
-void Channel::ForceJoin(User* user, const std::string* privs, bool bursting, bool created_by_local)
+Membership* Channel::ForceJoin(User* user, const std::string* privs, bool bursting, bool created_by_local)
 {
        if (IS_SERVER(user))
        {
                ServerInstance->Logs->Log("CHANNELS", LOG_DEBUG, "Attempted to join server user " + user->uuid + " to channel " + this->name);
-               return;
+               return NULL;
        }
 
        Membership* memb = this->AddUser(user);
        if (!memb)
-               return; // Already on the channel
+               return NULL; // Already on the channel
 
        user->chans.push_front(memb);
 
@@ -350,6 +348,7 @@ void Channel::ForceJoin(User* user, const std::string* privs, bool bursting, boo
        }
 
        FOREACH_MOD(OnPostJoin, (memb));
+       return memb;
 }
 
 bool Channel::IsBanned(User* user)