summaryrefslogtreecommitdiff
path: root/app.js
diff options
context:
space:
mode:
authorJules Laplace <jules@okfoc.us>2013-01-24 13:56:06 -0500
committerJules Laplace <jules@okfoc.us>2013-01-24 13:56:06 -0500
commit386b2a374b90638affc956b88a40c276207aa265 (patch)
tree2d83229a3d06cd79b651816a3e946b985c1c4af8 /app.js
parent44dfbc35bb66363b71c840ba8ceb76bd62fb51b9 (diff)
refactor
Diffstat (limited to 'app.js')
-rw-r--r--app.js4
1 files changed, 3 insertions, 1 deletions
diff --git a/app.js b/app.js
index 8b037b6..cab9f7a 100644
--- a/app.js
+++ b/app.js
@@ -204,7 +204,9 @@ io.sockets.on('connection', function (socket) {
var now = Date.now();
updateTime(socket.user, now, socket.connected);
socket.connected = now;
- users[socket.user.id].active = false;
+ if (socket.user.id in users) {
+ users[socket.user.id].active = false;
+ }
io.sockets.emit('blur', data);
});