summaryrefslogtreecommitdiff
path: root/src/modules/m_denychans.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/modules/m_denychans.cpp')
-rw-r--r--src/modules/m_denychans.cpp9
1 files changed, 4 insertions, 5 deletions
diff --git a/src/modules/m_denychans.cpp b/src/modules/m_denychans.cpp
index f47d414bd..f95c0b107 100644
--- a/src/modules/m_denychans.cpp
+++ b/src/modules/m_denychans.cpp
@@ -23,10 +23,9 @@ class ModuleDenyChannels : public Module
ConfigReader *Conf;
public:
- ModuleDenyChannels(InspIRCd* Me) : Module(Me)
- {
+ ModuleDenyChannels() {
- Conf = new ConfigReader(ServerInstance);
+ Conf = new ConfigReader;
Implementation eventlist[] = { I_OnUserPreJoin, I_OnRehash };
ServerInstance->Modules->Attach(eventlist, this, 2);
}
@@ -34,7 +33,7 @@ class ModuleDenyChannels : public Module
virtual void OnRehash(User* user)
{
delete Conf;
- Conf = new ConfigReader(ServerInstance);
+ Conf = new ConfigReader;
/* check for redirect validity and loops/chains */
for (int i =0; i < Conf->Enumerate("badchan"); i++)
{
@@ -116,7 +115,7 @@ class ModuleDenyChannels : public Module
if ((!newchan) || (!(newchan->IsModeSet('L'))))
{
user->WriteNumeric(926, "%s %s :Channel %s is forbidden, redirecting to %s: %s",user->nick.c_str(),cname,cname,redirect.c_str(), reason.c_str());
- Channel::JoinUser(ServerInstance,user,redirect.c_str(),false,"",false,ServerInstance->Time());
+ Channel::JoinUser(user,redirect.c_str(),false,"",false,ServerInstance->Time());
return MOD_RES_DENY;
}
}