Skip to content

Commit

Permalink
sort wods by date
Browse files Browse the repository at this point in the history
  • Loading branch information
mikepmunroe committed Mar 4, 2014
1 parent f5ecb40 commit 9d25b05
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion routes/wods.js
Expand Up @@ -4,7 +4,7 @@ var mongoose = require('mongoose'),
Wod = mongoose.model('Wod');

exports.findAll = function(req, res) {
Wod.find().exec(function(err, lifts) {
Wod.find().sort('date -test').exec(function(err, lifts) {
if (err) return res.json(500, err);
res.json(lifts);
});
Expand Down

0 comments on commit 9d25b05

Please sign in to comment.