@@ -108,7 +108,7 @@ public override void Load(bool hotReload)
108
108
[ RequiresPermissions ( "@css/root" ) ]
109
109
public void OnCommandMapConfig ( CCSPlayerController ? player , CommandInfo commandInfo )
110
110
{
111
- if ( ! Helpers . IsValidPlayer ( player ) )
111
+ if ( player != null && ! Helpers . IsValidPlayer ( player ) )
112
112
{
113
113
return ;
114
114
}
@@ -143,7 +143,7 @@ public void OnCommandMapConfig(CCSPlayerController? player, CommandInfo commandI
143
143
[ RequiresPermissions ( "@css/root" ) ]
144
144
public void OnCommandMapConfigs ( CCSPlayerController ? player , CommandInfo commandInfo )
145
145
{
146
- if ( player == null || ! Helpers . IsValidPlayer ( player ) )
146
+ if ( player != null && ! Helpers . IsValidPlayer ( player ) )
147
147
{
148
148
return ;
149
149
}
@@ -179,7 +179,7 @@ public void OnCommandMapConfigs(CCSPlayerController? player, CommandInfo command
179
179
[ RequiresPermissions ( "@css/root" ) ]
180
180
public void OnCommandForceBombsite ( CCSPlayerController ? player , CommandInfo commandInfo )
181
181
{
182
- if ( ! Helpers . IsValidPlayer ( player ) )
182
+ if ( player != null && ! Helpers . IsValidPlayer ( player ) )
183
183
{
184
184
return ;
185
185
}
@@ -201,7 +201,7 @@ public void OnCommandForceBombsite(CCSPlayerController? player, CommandInfo comm
201
201
[ RequiresPermissions ( "@css/root" ) ]
202
202
public void OnCommandForceBombsiteStop ( CCSPlayerController ? player , CommandInfo commandInfo )
203
203
{
204
- if ( ! Helpers . IsValidPlayer ( player ) )
204
+ if ( player != null && ! Helpers . IsValidPlayer ( player ) )
205
205
{
206
206
return ;
207
207
}
@@ -218,7 +218,7 @@ public void OnCommandForceBombsiteStop(CCSPlayerController? player, CommandInfo
218
218
[ RequiresPermissions ( "@css/root" ) ]
219
219
public void OnCommandShowSpawns ( CCSPlayerController ? player , CommandInfo commandInfo )
220
220
{
221
- if ( ! Helpers . IsValidPlayer ( player ) )
221
+ if ( player != null && ! Helpers . IsValidPlayer ( player ) )
222
222
{
223
223
return ;
224
224
}
0 commit comments