can read and display workouts

This commit is contained in:
2013-01-19 15:01:03 -05:00
parent 4ea082330b
commit 651a534523
140 changed files with 14677 additions and 29 deletions

View File

@@ -9,7 +9,7 @@ var UserSchema = new mongoose.Schema({
UserSchema.methods.recentworkouts = function(callback) {
return this.model('workout')
.find({author: this._id})
.find({userID: this._id})
//.sort('created_at', 1)
.limit(5)
.exec(callback);