mirror of
https://github.com/HifiExperiments/overte.git
synced 2025-08-04 06:24:41 +02:00
fixed spacing of app.js
This commit is contained in:
parent
7ea0a626d9
commit
1c8b3e394c
1 changed files with 14 additions and 6 deletions
|
@ -33,16 +33,24 @@ wsServer.on('request', function(request) {
|
|||
// This user already exists, so just update score
|
||||
users[users.indexOf(user)].score = userData.score;
|
||||
} else {
|
||||
users.push({id: shortid.generate(), username: userData.username, score: userData.score});
|
||||
users.push({
|
||||
id: shortid.generate(),
|
||||
username: userData.username,
|
||||
score: userData.score
|
||||
});
|
||||
}
|
||||
connections.forEach(function(aConnection) {
|
||||
aConnection.sendUTF(JSON.stringify({users: users}));
|
||||
aConnection.sendUTF(JSON.stringify({
|
||||
users: users
|
||||
}));
|
||||
})
|
||||
});
|
||||
});
|
||||
|
||||
app.get('/users', function(req, res) {
|
||||
res.send({users: users});
|
||||
res.send({
|
||||
users: users
|
||||
});
|
||||
});
|
||||
|
||||
|
||||
|
|
Loading…
Reference in a new issue