X-Git-Url: https://git.netwichtig.de/gitweb/?a=blobdiff_plain;f=src%2Fmodules%2Fm_chgname.cpp;h=45d584dc8c3c5a02662c3dd3196405ebbbdf5551;hb=cb4c516ace8fef75b8a54a141c3644af9697ac0a;hp=0f9302a76c052afaf8610eea819df5e679d77276;hpb=68174076d7d665340ca992f88013dc2e6035a0a8;p=user%2Fhenk%2Fcode%2Finspircd.git diff --git a/src/modules/m_chgname.cpp b/src/modules/m_chgname.cpp index 0f9302a76..45d584dc8 100644 --- a/src/modules/m_chgname.cpp +++ b/src/modules/m_chgname.cpp @@ -2,7 +2,7 @@ * | Inspire Internet Relay Chat Daemon | * +------------------------------------+ * - * InspIRCd: (C) 2002-2009 InspIRCd Development Team + * InspIRCd: (C) 2002-2010 InspIRCd Development Team * See: http://wiki.inspircd.org/Credits * * This program is free but copyrighted software; see @@ -20,8 +20,9 @@ class CommandChgname : public Command { public: - CommandChgname (InspIRCd* Instance, Module* Creator) : Command(Instance, Creator,"CHGNAME", "o", 2, 2) + CommandChgname(Module* Creator) : Command(Creator,"CHGNAME", 2, 2) { + flags_needed = 'o'; syntax = " "; TRANSLATE3(TR_NICK, TR_TEXT, TR_END); } @@ -36,12 +37,6 @@ class CommandChgname : public Command return CMD_FAILURE; } - if (parameters[1].empty()) - { - user->WriteServ("NOTICE %s :*** GECOS must be specified", user->nick.c_str()); - return CMD_FAILURE; - } - if (parameters[1].length() > ServerInstance->Config->Limits.MaxGecos) { user->WriteServ("NOTICE %s :*** GECOS too long", user->nick.c_str()); @@ -72,7 +67,7 @@ class ModuleChgName : public Module CommandChgname cmd; public: - ModuleChgName(InspIRCd* Me) : Module(Me), cmd(Me, this) + ModuleChgName() : cmd(this) { ServerInstance->AddCommand(&cmd); } @@ -83,7 +78,7 @@ public: virtual Version GetVersion() { - return Version("$Id$", VF_OPTCOMMON | VF_VENDOR, API_VERSION); + return Version("Provides support for the CHGNAME command", VF_OPTCOMMON | VF_VENDOR); } };