public:
/** Constructor for modules.
*/
- CommandModules ( Module* parent) : Command(parent,"MODULES",0,0) { syntax = "[server]"; }
+ CommandModules(Module* parent) : Command(parent,"MODULES",0,0)
+ {
+ Penalty = 4;
+ syntax = "[<servername>]";
+ }
+
/** Handle command.
* @param parameters The parameters to the comamnd
* @param pcnt The number of parameters passed to teh command
/** Handle /MODULES
*/
-CmdResult CommandModules::Handle (const std::vector<std::string>&, User *user)
+CmdResult CommandModules::Handle (const std::vector<std::string>& parameters, User *user)
{
+ if (parameters.size() >= 1 && parameters[0] != ServerInstance->Config->ServerName)
+ return CMD_SUCCESS;
+
std::vector<std::string> module_names = ServerInstance->Modules->GetAllModuleNames(0);
for (unsigned int i = 0; i < module_names.size(); i++)
Module* m = ServerInstance->Modules->Find(module_names[i]);
Version V = m->GetVersion();
- if (user->HasPrivPermission("servers/auspex"))
+ if (IS_LOCAL(user) && user->HasPrivPermission("servers/auspex"))
{
std::string flags("SvcC");
int pos = 0;