1
0
Fork 0
mirror of https://codeberg.org/demostf/api.git synced 2026-06-03 18:04:08 +02:00

handle classless players

This commit is contained in:
Robin Appelman 2018-03-08 23:15:22 +01:00
commit 7df8f24ad5

View file

@ -84,12 +84,12 @@ class Parser {
$class = $classId;
}
}
if ($class && $player['steamId']) {//skip spectators
if ($player['steamId'] && $player['steamId'] !== 'BOT') {//skip spectators
$players[] = new ParsedPlayer(
$player['name'],
$player['userId'],
$this->convertSteamIdToCommunityId($player['steamId']),
$player['team'],
$player['team'] ?? '',
$this->getClassName((int) $class)
);
}