X-Git-Url: https://git.netwichtig.de/gitweb/?a=blobdiff_plain;f=src%2Fmessage.cpp;h=6d5941f7e7ea5042eaa1d795e593b552c3c2d0cd;hb=eb28eaea35d9d109a0b7b890de9d957d562da675;hp=f2a41a59be216a9ae899e0d4858e92e0a9262bf9;hpb=09afa5085614e0224a296abd082fce205003c3fe;p=user%2Fhenk%2Fcode%2Finspircd.git diff --git a/src/message.cpp b/src/message.cpp index f2a41a59b..6d5941f7e 100644 --- a/src/message.cpp +++ b/src/message.cpp @@ -183,28 +183,3 @@ int cstatus(userrec *user, chanrec *chan) return STATUS_NORMAL; } -std::string chlist(userrec *user,userrec* source) -{ - std::string list; - - if (!user || !source) - return ""; - - for (std::vector::const_iterator i = user->chans.begin(); i != user->chans.end(); i++) - { - ucrec* rec = *i; - - if(rec->channel && rec->channel->name) - { - /* If the target is the same as the sender, let them see all their channels. - * If the channel is NOT private/secret OR the user shares a common channel - * If the user is an oper, and the option is set. - */ - if ((source == user) || (*source->oper && ServerInstance->Config->OperSpyWhois) || (((!rec->channel->modes[CM_PRIVATE]) && (!rec->channel->modes[CM_SECRET])) || (rec->channel->HasUser(source)))) - { - list.append(cmode(user, rec->channel)).append(rec->channel->name).append(" "); - } - } - } - return list; -}