]> git.netwichtig.de Git - user/henk/code/inspircd.git/blobdiff - src/modules/m_muteban.cpp
Expand searching in m_httpd_stats, add global handling of GET parameters (#1566)
[user/henk/code/inspircd.git] / src / modules / m_muteban.cpp
index aebc004623d7aa0a68314802cfe8ffe57bb3278b..61d592b2b9dba45bea8d60905e0f7aa247b1d339 100644 (file)
 
 class ModuleQuietBan : public Module
 {
+ private:
+       bool notifyuser;
+
  public:
+       void ReadConfig(ConfigStatus& status) CXX11_OVERRIDE
+       {
+               ConfigTag* tag = ServerInstance->Config->ConfValue("muteban");
+               notifyuser = tag->getBool("notifyuser", true);
+       }
+
        Version GetVersion() CXX11_OVERRIDE
        {
                return Version("Implements extban +b m: - mute bans",VF_OPTCOMMON|VF_VENDOR);
@@ -36,10 +45,9 @@ class ModuleQuietBan : public Module
                Channel* chan = target.Get<Channel>();
                if (chan->GetExtBanStatus(user, 'm') == MOD_RES_DENY && chan->GetPrefixValue(user) < VOICE_VALUE)
                {
-                       bool notifyuser = ServerInstance->Config->ConfValue("muteban")->getBool("notifyuser", true);
                        if (!notifyuser)
                        {
-                               details.echooriginal = true;
+                               details.echo_original = true;
                                return MOD_RES_DENY;
                        }