]> git.netwichtig.de Git - user/henk/code/inspircd.git/blobdiff - src/modules/m_timedbans.cpp
(Hopefully) fix a issue with m_ident's result not being used for display.
[user/henk/code/inspircd.git] / src / modules / m_timedbans.cpp
index e18bca6a5ee9a386b09d7742af256bce937ebb8f..53d67e8ab8a764b559411e4463e785fa304dff40 100644 (file)
@@ -153,20 +153,20 @@ class ModuleTimedBans : public Module
                {
                        if (curtime > i->expire)
                        {
-                               std::string chan = i->mask;
+                               std::string chan = i->channel;
                                std::string mask = i->mask;
                                Channel* cr = ServerInstance->FindChan(chan);
                                i = TimedBanList.erase(i);
                                if (cr)
                                {
                                        std::vector<std::string> setban;
-                                       setban.push_back(safei->channel);
+                                       setban.push_back(chan);
                                        setban.push_back("-b");
                                        setban.push_back(mask);
 
                                        CUList empty;
-                                       std::string expiry = "*** Timed ban on " + safei->mask + " expired.";
-                                       cr->WriteChannelWithServ(ServerInstance->FakeClient, true, '@', empty, "NOTICE %s :%s", cr->name.c_str(), expiry.c_str());
+                                       std::string expiry = "*** Timed ban on " + chan + " expired.";
+                                       cr->WriteAllExcept(ServerInstance->FakeClient, true, '@', empty, "NOTICE %s :%s", cr->name.c_str(), expiry.c_str());
                                        ServerInstance->PI->SendChannelNotice(cr, '@', expiry);
                                        if (ServerInstance->Config->AllowHalfop)
                                        {