X-Git-Url: http://git.pk910.de/?a=blobdiff_plain;f=src%2Fmodules%2Fglobal.mod%2Fcmd_global_unregister.c;fp=src%2Fmodules%2Fglobal.mod%2Fcmd_global_unregister.c;h=be17ea25cb114aa33328c82049b7871a00525448;hb=de5f0224c8b119f1be15457262bd6e66f160657f;hp=37149bc24b15e1a64ddf3a1f71f6eef546080e62;hpb=9f5af1bc8ff4e8fc9c28433c76a890a990dd0ae5;p=NeonServV5.git diff --git a/src/modules/global.mod/cmd_global_unregister.c b/src/modules/global.mod/cmd_global_unregister.c index 37149bc..be17ea2 100644 --- a/src/modules/global.mod/cmd_global_unregister.c +++ b/src/modules/global.mod/cmd_global_unregister.c @@ -30,7 +30,7 @@ CMD_BIND(global_cmd_unregister) { else channel = (chan ? chan->name : ""); if(!is_valid_chan(channel)) { - reply(getTextBot(), user, "NS_INVALID_CHANNEL_NAME", channel); + reply(textclient, user, "NS_INVALID_CHANNEL_NAME", channel); return; } int chanid; @@ -39,11 +39,11 @@ CMD_BIND(global_cmd_unregister) { if ((row = mysql_fetch_row(res)) != NULL) { chanid = atoi(row[0]); } else { - reply(getTextBot(), user, "NS_UNREGISTER_NOT_REGISTERED", channel, client->user->nick); + reply(textclient, user, "NS_UNREGISTER_NOT_REGISTERED", channel, client->user->nick); return; } if(client->botid == NEONSERV_BOTID && !strcmp(row[1], "1")) { - reply(getTextBot(), user, "NS_UNREGISTER_NODELETE", channel); + reply(textclient, user, "NS_UNREGISTER_NODELETE", channel); return; } int sync_neonspam_unreg = get_int_field("General.sync_neonspam_unreg"); @@ -53,7 +53,7 @@ CMD_BIND(global_cmd_unregister) { printf_mysql_query("SELECT `botid`, `bot_channels`.`id`, `suspended` FROM `bot_channels` LEFT JOIN `bots` ON `bot_channels`.`botid` = `bots`.`id` WHERE `chanid` = '%d' AND `botclass` = '%d'", chanid, client->botid); res = mysql_use(); if ((row = mysql_fetch_row(res)) == NULL) { - reply(getTextBot(), user, "NS_UNREGISTER_NOT_REGISTERED", channel, client->user->nick); + reply(textclient, user, "NS_UNREGISTER_NOT_REGISTERED", channel, client->user->nick); return; } int botid = atoi(row[0]); @@ -63,7 +63,7 @@ CMD_BIND(global_cmd_unregister) { break; } printf_mysql_query("DELETE FROM `bot_channels` WHERE `id` = '%s'", row[1]); - reply(getTextBot(), user, "NS_UNREGISTER_DONE", channel); + reply(textclient, user, "NS_UNREGISTER_DONE", channel); if(bot && strcmp(row[2], "1")) { putsock(bot, "PART %s :Channel unregistered.", channel); }