@@ -37,12+37,6 @@ class CommandChgident : public Command
return CMD_FAILURE;
}
return CMD_FAILURE;
}
- if (parameters[1].empty())
- {
- user->WriteServ("NOTICE %s :*** CHGIDENT: Ident must be specified", user->nick.c_str());
- return CMD_FAILURE;
- }
-
if (parameters[1].length() > ServerInstance->Config->Limits.IdentMax)
{
user->WriteServ("NOTICE %s :*** CHGIDENT: Ident is too long", user->nick.c_str());
if (parameters[1].length() > ServerInstance->Config->Limits.IdentMax)
{
user->WriteServ("NOTICE %s :*** CHGIDENT: Ident is too long", user->nick.c_str());
@@ -55,28+49,35 @@ class CommandChgident : public Command
return CMD_FAILURE;
}
return CMD_FAILURE;
}
- dest->ChangeIdent(parameters[1].c_str());
+ if (IS_LOCAL(dest))
+ {
+ dest->ChangeIdent(parameters[1].c_str());
- if (!ServerInstance->ULine(user->server))
- ServerInstance->SNO->WriteToSnoMask('A', "%s used CHGIDENT to change %s's ident to '%s'", user->nick.c_str(), dest->nick.c_str(), dest->ident.c_str());
+ if (!ServerInstance->ULine(user->server))
+ ServerInstance->SNO->WriteGlobalSno('a', "%s used CHGIDENT to change %s's ident to '%s'", user->nick.c_str(), dest->nick.c_str(), dest->ident.c_str());