From f9cdad51d3af697cf5b061c21840970815b57cf0 Mon Sep 17 00:00:00 2001 From: Jules Laplace Date: Thu, 24 Jan 2013 18:13:53 -0500 Subject: sorting --- app.js | 4 ++-- public/stylesheets/style.css | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/app.js b/app.js index 81f87b4..3610b08 100644 --- a/app.js +++ b/app.js @@ -137,7 +137,7 @@ function updateTime ( user, now, connected ) { } function getHighScores (callback) { - return User.find({}).sort({ score: 'desc' }).limit(10).exec(callback); + return User.find({}).sort('-count').limit(10).exec(callback); } var io = require("socket.io").listen(server), userCount = 0, users = {}, timeout; @@ -158,7 +158,7 @@ io.sockets.on('connection', function (socket) { }); } socket.emit('scores', { - 'scores': scores.reverse(), + 'scores': scores, 'users': users, 'now': Date.now() }) diff --git a/public/stylesheets/style.css b/public/stylesheets/style.css index 20d3ba1..aa6d16e 100644 --- a/public/stylesheets/style.css +++ b/public/stylesheets/style.css @@ -426,7 +426,7 @@ top:0; } .cursor.idle div { color: transparent; - text-shadow: none; + text-shadow: 0 0 2px #000; } ol { -- cgit v1.2.3-70-g09d2