check for own property in for (var _ in _ )

This commit is contained in:
Eric Rosenbaum 2017-02-02 15:10:10 -05:00
parent 1a26fecca1
commit b68c84af02

View file

@ -72,7 +72,9 @@ PitchEffect.prototype.updatePlayers = function (players) {
if (!players) return;
for (var md5 in players) {
this.updatePlayer(players[md5]);
if (players.hasOwnProperty(md5)) {
this.updatePlayer(players[md5]);
}
}
};