]> git.netwichtig.de Git - user/henk/code/inspircd.git/blobdiff - src/modules/m_hostchange.cpp
m_nokicks Remove u-line check, OnUserPreKick doesn't run in that case
[user/henk/code/inspircd.git] / src / modules / m_hostchange.cpp
index b137f14188b6d3144e48f053e8b089ec8cf158ec..508171c967216f74cf3ecb5428f27fda5c2fda67 100644 (file)
@@ -63,10 +63,10 @@ class ModuleHostChange : public Module
 
        virtual void OnRehash(User* user)
        {
-               ConfigReader Conf;
-               MySuffix = Conf.ReadValue("host","suffix",0);
-               MyPrefix = Conf.ReadValue("host","prefix","",0);
-               MySeparator = Conf.ReadValue("host","separator",".",0);
+               ConfigTag* host = ServerInstance->Config->ConfValue("host");
+               MySuffix = host->getString("suffix");
+               MyPrefix = host->getString("prefix");
+               MySeparator = host->getString("separator", ".");
                hostchanges.clear();
 
                std::set<std::string> dupecheck;
@@ -93,7 +93,7 @@ class ModuleHostChange : public Module
                        else
                                throw ModuleException("Invalid hostchange action: " + action);
 
-                       hostchanges.push_back(std::make_pair(mask, Host(act, tag->getString("ports"), newhost)));
+                       hostchanges.push_back(std::make_pair(mask, Host(act, newhost, tag->getString("ports"))));
                }
        }