}
ModeHandler *mh = this->FindMode(*mode, MODETYPE_CHANNEL);
+ bool display = true;
if ((mh) && (mh->IsListMode()))
{
{
std::string dummyparam;
- if((*watchers)->BeforeMode(user, NULL, targetchannel, dummyparam, true, MODETYPE_CHANNEL) == MODEACTION_ALLOW)
- {
- mh->DisplayList(user, targetchannel);
- }
+ if((*watchers)->BeforeMode(user, NULL, targetchannel, dummyparam, true, MODETYPE_CHANNEL) == MODEACTION_DENY)
+ display = false;
}
+
+ if (display)
+ mh->DisplayList(user, targetchannel);
}
mode++;