Skip to content

Commit

Permalink
Fix player SteamIDs
Browse files Browse the repository at this point in the history
  • Loading branch information
andrewda committed Aug 10, 2016
1 parent dcb0a62 commit 15673f1
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/classes/Player.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
var SteamID = require('steamid');

function Player(player) {
this.steamid = fixSteamid(player.steamid);
this.steamid = fixSteamid(player.steamId);
this.hltvid = parseInt(player.dbId);

this.name = player.name;
Expand All @@ -21,7 +21,7 @@ function fixSteamid(steamid) {
return new SteamID(steamid);
} catch (e) {
var splitid = steamid.split(':');
return new SteamID('[U:' + splitid[1] + ':' + splitid[2] + ']')
return new SteamID('STEAM_'+steamid)
}
}

Expand Down

0 comments on commit 15673f1

Please sign in to comment.