Fixed lack of error checking on sm_motd. (bug 4460, r=dvander)

This commit is contained in:
Erik Minekus 2010-06-23 23:42:22 -04:00
parent 9270399eb1
commit f1bcb2ad3e

View File

@ -210,6 +210,12 @@ public Action:Command_Nextmap(client, args)
public Action:Command_Motd(client, args) public Action:Command_Motd(client, args)
{ {
if (client == 0)
{
ReplyToCommand(client, "[SM] %t", "Command is in-game only");
return Plugin_Handled;
}
ShowMOTDPanel(client, "Message Of The Day", "motd", MOTDPANEL_TYPE_INDEX); ShowMOTDPanel(client, "Message Of The Day", "motd", MOTDPANEL_TYPE_INDEX);
return Plugin_Handled; return Plugin_Handled;