summaryrefslogtreecommitdiff
path: root/src/modules
diff options
context:
space:
mode:
authorbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2004-05-02 16:16:04 +0000
committerbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2004-05-02 16:16:04 +0000
commit23303627e1c689b825445af20d682c886a800bb6 (patch)
tree8635be4261e4077d3342aa503510ef87640822f9 /src/modules
parentfe23c1d1817b207e7ce311e11ecab18471ed20b9 (diff)
Added +O mode support through m_operchans.so
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@785 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'src/modules')
-rw-r--r--src/modules/m_operchans.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/modules/m_operchans.cpp b/src/modules/m_operchans.cpp
index 461b7bece..ba9a4d79f 100644
--- a/src/modules/m_operchans.cpp
+++ b/src/modules/m_operchans.cpp
@@ -17,7 +17,7 @@ class ModuleOperChans : public Module
Srv = new Server;
// Add a mode +O for channels with no parameters
- Srv->AddExtendedMode('Z',MT_CHANNEL,false,0,0);
+ Srv->AddExtendedMode('O',MT_CHANNEL,false,0,0);
}
virtual int OnExtendedMode(userrec* user, void* target, char modechar, int type, bool mode_on, string_list &params)
@@ -26,7 +26,7 @@ class ModuleOperChans : public Module
{
chanrec* chan = (chanrec*)target;
- if ((Srv->IsUlined(source->nick)) || (Srv->IsUlined(source->server)) || (!strcmp(source->server,"")) || (strchr(source->modes,'o')))
+ if ((Srv->IsUlined(user->nick)) || (Srv->IsUlined(user->server)) || (!strcmp(user->server,"")) || (strchr(user->modes,'o')))
{
return 1;
}
@@ -34,7 +34,7 @@ class ModuleOperChans : public Module
{
// eat the mode change, return an error
WriteServ(user->fd,"468 %s %s :Only servers and opers may set channel mode +O",user->nick, chan->name);
- return -1;
+ return 0;
}
// must return 1 to handle the mode!