e5c5319408b8a53a0d21a225b3473a61a092d840
[NeonServV5.git] / cmd_neonserv_inviteme.c
1
2 /*
3 * no arguments
4 */
5
6 static CMD_BIND(neonserv_cmd_inviteme) {
7     if(getChanUser(user, chan)) {
8         reply(getTextBot(), user, "NS_INVITEME_ON_CHAN", chan->name);
9         /* BUG
10          This check does not work if the user is invisible (CHMODE +D/+d)
11          to fix this we'd need to request the full userlist...
12          this is really senseless to invite a simple user so we simply mark this bug as unsolvable.
13         */
14         return;
15     }
16     putsock(client, "INVITE %s %s", user->nick, chan->name);
17     reply(getTextBot(), user, "NS_INVITEME_DONE", chan->name);
18 }