*/
#include "inspircd.h"
-#include "users.h"
-#include "channels.h"
-#include "modules.h"
/* $ModDesc: Forces opers to join the specified channel(s) on oper-up */
List[I_OnPostOper] = List[I_OnRehash] = 1;
}
- virtual void OnRehash(userrec* user, const std::string ¶meter)
+ virtual void OnRehash(User* user, const std::string ¶meter)
{
ConfigReader* conf = new ConfigReader(ServerInstance);
if (!operChan.empty())
tokenize(operChan,operChans);
- DELETE(conf);
+ delete conf;
}
virtual ~ModuleOperjoin()
return Version(1,1,0,1,VF_VENDOR,API_VERSION);
}
- virtual void OnPostOper(userrec* user, const std::string &opertype)
+ virtual void OnPostOper(User* user, const std::string &opertype)
{
if (!IS_LOCAL(user))
return;
for(std::vector<std::string>::iterator it = operChans.begin(); it != operChans.end(); it++)
if (ServerInstance->IsChannel(it->c_str()))
- chanrec::JoinUser(ServerInstance, user, it->c_str(), false, "", ServerInstance->Time(true));
+ Channel::JoinUser(ServerInstance, user, it->c_str(), false, "", ServerInstance->Time(true));
}
};
-MODULE_INIT(ModuleOperjoin);
+MODULE_INIT(ModuleOperjoin)