*/
#include "inspircd.h"
-#include "configreader.h"
-#include "users.h"
-#include "modules.h"
#include "commands/cmd_invite.h"
extern "C" DllExport command_t* init_command(InspIRCd* Instance)
{
if (c->GetStatus(user) < STATUS_HOP)
{
- user->WriteServ("482 %s %s :You must be at least a half-operator to change modes on this channel",user->nick, c->name);
+ user->WriteServ("482 %s %s :You must be a channel %soperator", user->nick, c->name, c->GetStatus(u) == STATUS_HOP ? "" : "half-");
return CMD_FAILURE;
}
}
case ServerConfig::INVITE_ANNOUNCE_OPS:
c->WriteAllExceptSender(user, true, '@', "NOTICE %s :*** %s invited %s into the channel", c->name, user->nick, u->nick);
break;
+ case ServerConfig::INVITE_ANNOUNCE_DYNAMIC:
+ if (c->IsModeSet('i'))
+ c->WriteAllExceptSender(user, true, '@', "NOTICE %s :*** %s invited %s into the channel", c->name, user->nick, u->nick);
+ else
+ c->WriteChannelWithServ(ServerInstance->Config->ServerName, "NOTICE %s :*** %s invited %s into the channel", c->name, user->nick, u->nick);
+ break;
default:
/* Nobody */
break;