aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/models/pPost.js
diff options
context:
space:
mode:
Diffstat (limited to 'models/pPost.js')
-rw-r--r--models/pPost.js4
1 files changed, 2 insertions, 2 deletions
diff --git a/models/pPost.js b/models/pPost.js
index c6def28..d36eb36 100644
--- a/models/pPost.js
+++ b/models/pPost.js
@@ -52,7 +52,7 @@ pPostSchema.statics = {
loadProject: function(project, callback) {
this.find({ project: project })
.populate('user')
- .sort({ 'when': -1 })
+ .sort({ 'when': -1, 'created': -1 })
.exec(callback);
},
@@ -70,7 +70,7 @@ pPostSchema.statics = {
.populate({ path: 'user', select: 'name email status' })
.populate({ path: 'project', select: 'name shortURL' })
.limit(10)
- .sort({ 'when': -1 })
+ .sort({ 'when': -1, 'created': -1 })
.exec(callback);
}