void Send(LocalUser* user, Command* command, const std::string& code, const std::string& description)
{
ClientProtocol::Message msg(cmd.c_str(), ServerInstance->Config->GetServerName());
- msg.PushParamRef(command->name);
+ if (command)
+ msg.PushParamRef(command->name);
+ else
+ msg.PushParam("*");
msg.PushParam(code);
msg.PushParam(description);
SendInternal(user, msg);
void Send(LocalUser* user, Command* command, const std::string& code, const T1& p1, const std::string& description)
{
ClientProtocol::Message msg(cmd.c_str(), ServerInstance->Config->GetServerName());
- msg.PushParamRef(command->name);
+ if (command)
+ msg.PushParamRef(command->name);
+ else
+ msg.PushParam("*");
msg.PushParam(code);
msg.PushParam(ConvToStr(p1));
msg.PushParam(description);
const std::string& description)
{
ClientProtocol::Message msg(cmd.c_str(), ServerInstance->Config->GetServerName());
- msg.PushParamRef(command->name);
+ if (command)
+ msg.PushParamRef(command->name);
+ else
+ msg.PushParam("*");
msg.PushParam(code);
msg.PushParam(ConvToStr(p1));
msg.PushParam(ConvToStr(p2));
const T3& p3, const std::string& description)
{
ClientProtocol::Message msg(cmd.c_str(), ServerInstance->Config->GetServerName());
- msg.PushParamRef(command->name);
+ if (command)
+ msg.PushParamRef(command->name);
+ else
+ msg.PushParam("*");
msg.PushParam(code);
msg.PushParam(ConvToStr(p1));
msg.PushParam(ConvToStr(p2));
const T3& p3, const T4& p4, const std::string& description)
{
ClientProtocol::Message msg(cmd.c_str(), ServerInstance->Config->GetServerName());
- msg.PushParamRef(command->name);
+ if (command)
+ msg.PushParamRef(command->name);
+ else
+ msg.PushParam("*");
msg.PushParam(code);
msg.PushParam(ConvToStr(p1));
msg.PushParam(ConvToStr(p2));