I tried the Meteors Leaderboard example and am in error trying to randomize player ratings.
Exception Im hit Exception while simulating the effect of invoking '/players/update' undefined
The corresponding code is as follows:
'click input.randomize_scores': function () { Players.find().forEach(function (player) { random_score = Math.floor(Math.random()*10)*5; Players.update(player, {$set: {score: random_score}}) }); }
The full contents of leaderboard.js are here
It seems to me that I'm doing something pretty stupid here. Id really appreciate the pointer.
Edward Ocampo-Gooding
source share