]> git.netwichtig.de Git - user/henk/code/inspircd.git/blobdiff - src/modules/m_services_account.cpp
Merge insp20
[user/henk/code/inspircd.git] / src / modules / m_services_account.cpp
index bdd47b4bc8f0764b0563bb3c300ad7283142eee4..81ff3e4c3c2b4f533755a13e4214c409f96804b9 100644 (file)
@@ -37,7 +37,7 @@ class Channel_r : public ModeHandler
        ModeAction OnModeChange(User* source, User* dest, Channel* channel, std::string &parameter, bool adding)
        {
                // only a u-lined server may add or remove the +r mode.
-               if (!IS_LOCAL(source) || ServerInstance->ULine(source->server))
+               if (!IS_LOCAL(source))
                {
                        // Only change the mode if it's not redundant
                        if ((adding != channel->IsModeSet('r')))
@@ -64,7 +64,7 @@ class User_r : public ModeHandler
 
        ModeAction OnModeChange(User* source, User* dest, Channel* channel, std::string &parameter, bool adding)
        {
-               if (!IS_LOCAL(source) || ServerInstance->ULine(source->server))
+               if (!IS_LOCAL(source))
                {
                        if ((adding != dest->IsModeSet('r')))
                        {
@@ -171,12 +171,6 @@ class ModuleServicesAccount : public Module
                std::string *account = accountname.get(user);
                bool is_registered = account && !account->empty();
 
-               if ((ServerInstance->ULine(user->nick.c_str())) || (ServerInstance->ULine(user->server)))
-               {
-                       // user is ulined, can speak regardless
-                       return MOD_RES_PASSTHRU;
-               }
-
                if (target_type == TYPE_CHANNEL)
                {
                        Channel* c = (Channel*)dest;
@@ -245,22 +239,13 @@ class ModuleServicesAccount : public Module
                return OnUserPreMessage(user, dest, target_type, text, status, exempt_list);
        }
 
-       ModResult OnUserPreJoin(User* user, Channel* chan, const std::string& cname, std::string& privs, const std::string& keygiven)
+       ModResult OnUserPreJoin(LocalUser* user, Channel* chan, const std::string& cname, std::string& privs, const std::string& keygiven)
        {
-               if (!IS_LOCAL(user))
-                       return MOD_RES_PASSTHRU;
-
                std::string *account = accountname.get(user);
                bool is_registered = account && !account->empty();
 
                if (chan)
                {
-                       if ((ServerInstance->ULine(user->nick.c_str())) || (ServerInstance->ULine(user->server)))
-                       {
-                               // user is ulined, won't be stopped from joining
-                               return MOD_RES_PASSTHRU;
-                       }
-
                        if (chan->IsModeSet('R'))
                        {
                                if (!is_registered)