Merge pull request #1531 from coralproject/indexes

Adds Author Index for Comments
This commit is contained in:
Kim Gardner
2018-04-18 16:32:44 -04:00
committed by GitHub
+11
View File
@@ -187,6 +187,17 @@ Comment.index(
}
);
// Add an index that is optimized for finding a user's comments.
Comment.index(
{
author_id: 1,
created_at: -1,
},
{
background: true,
}
);
// Optimize for tag searches/counts.
Comment.index(
{