mirror of
https://github.com/wassname/talk.git
synced 2026-08-12 12:30:39 +08:00
Test was failing as I was not returning an error.
This commit is contained in:
@@ -92,6 +92,15 @@ const CommentSchema = new Schema({
|
||||
}
|
||||
});
|
||||
|
||||
// Add the indexes on the comment tag.
|
||||
CommentSchema.index({
|
||||
'id': 1,
|
||||
'tags.id': 1
|
||||
}, {
|
||||
unique: true,
|
||||
background: false
|
||||
});
|
||||
|
||||
// Comment model.
|
||||
const Comment = mongoose.model('Comment', CommentSchema);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user