diff --git a/server.js b/server.js index 4c6d23e..c643966 100644 --- a/server.js +++ b/server.js @@ -69,7 +69,8 @@ app.get('/', function (req, res) { database.each("SELECT * FROM players", function(err, row) { console.log('Received a player row! Weheeeee!'); console.log(row.name); - players.push(row.name); + var nextElement = players.length; + players[nextElement] = row.name; }); console.log(players);