CIRCChannel.getUsersLength Member
Syntax
object.getUsersLength(mode);
Arguments
Argument | Summary |
---|---|
mode |
Returns
Remarks
See Also
Source Code
function chan_userslen (mode)
{
var i = 0;
var p;
this.opCount = 0;
this.halfopCount = 0;
this.voiceCount = 0;
if (typeof mode == "undefined")
{
for (p in this.users)
{
if (this.users[p].isOp)
this.opCount++;
if (this.users[p].isHalfOp)
this.halfopCount++;
if (this.users[p].isVoice)
this.voiceCount++;
i++;
}
}
else
{
for (p in this.users)
if (arrayContains(this.users[p].modes, mode))
i++;
}
return i;
}