Skip to content

Commit

Permalink
Remove bad check for channel op in m_auditorium, fixes bug #886
Browse files Browse the repository at this point in the history
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@11441 e03df62e-2008-0410-955e-edbf42e46eb7
  • Loading branch information
danieldg committed Jul 7, 2009
1 parent db3b51a commit 6eeecaa
Showing 1 changed file with 3 additions and 11 deletions.
14 changes: 3 additions & 11 deletions src/modules/m_auditorium.cpp
Expand Up @@ -18,22 +18,14 @@
class AuditoriumMode : public ModeHandler
{
public:
AuditoriumMode(InspIRCd* Instance) : ModeHandler(Instance, 'u', 0, 0, false, MODETYPE_CHANNEL, false) { }
AuditoriumMode(InspIRCd* Instance) : ModeHandler(Instance, 'u', 0, 0, false, MODETYPE_CHANNEL, false, 0, '@') { }

ModeAction OnModeChange(User* source, User* dest, Channel* channel, std::string &parameter, bool adding, bool)
{
if (channel->IsModeSet('u') != adding)
{
if (IS_LOCAL(source) && (channel->GetStatus(source) < STATUS_OP))
{
source->WriteNumeric(ERR_CHANOPRIVSNEEDED, "%s %s :Only channel operators may %sset channel mode +u", source->nick.c_str(), channel->name.c_str(), adding ? "" : "un");
return MODEACTION_DENY;
}
else
{
channel->SetMode('u', adding);
return MODEACTION_ALLOW;
}
channel->SetMode('u', adding);
return MODEACTION_ALLOW;
}
else
{
Expand Down

0 comments on commit 6eeecaa

Please sign in to comment.