Browse Source

findAllTravelsFromUsername filter by future dates

master
idoctnef 8 years ago
parent
commit
0fb507c485
1 changed files with 2 additions and 1 deletions
  1. +2
    -1
      controllers/travelController.js

+ 2
- 1
controllers/travelController.js

@ -31,7 +31,8 @@ exports.findById = function(req, res) {
exports.findAllTravelsFromUsername = function(req, res) {
travelModel.find({
owner: req.params.username
owner: req.params.username,
date: {$gte: new Date()}
}, function(err, travels) {
if (err) throw err;

Loading…
Cancel
Save