Fixed lack of error checking on sm_motd. (bug 4460, r=dvander)
authorErik Minekus <erik@interwavestudios.com>
Wed Jun 23 23:41:47 2010 -0400 (2010-06-23)
changeset 3052a102c645bf4b
parent 3051 d359a575f7fb
child 3053 56afc7b83a4b
Fixed lack of error checking on sm_motd. (bug 4460, r=dvander)
plugins/basetriggers.sp
     1.1 --- a/plugins/basetriggers.sp	Wed Jun 23 23:40:53 2010 -0400
     1.2 +++ b/plugins/basetriggers.sp	Wed Jun 23 23:41:47 2010 -0400
     1.3 @@ -210,6 +210,12 @@
     1.4  
     1.5  public Action:Command_Motd(client, args)
     1.6  {
     1.7 +	if (client == 0)
     1.8 +	{
     1.9 +		ReplyToCommand(client, "[SM] %t", "Command is in-game only");
    1.10 +		return Plugin_Handled;
    1.11 +	}
    1.12 +
    1.13  	ShowMOTDPanel(client, "Message Of The Day", "motd", MOTDPANEL_TYPE_INDEX);
    1.14  
    1.15  	return Plugin_Handled;