Skip to content
Snippets Groups Projects
Commit c73c4f0e authored by P1384's avatar P1384
Browse files

Update Article.js

parent 1d3e1425
No related branches found
No related tags found
No related merge requests found
Pipeline #281796 passed
...@@ -12,7 +12,7 @@ var ArticleSchema = new mongoose.Schema({ ...@@ -12,7 +12,7 @@ var ArticleSchema = new mongoose.Schema({
comments: [{ type: mongoose.Schema.Types.ObjectId, ref: 'Comment' }], comments: [{ type: mongoose.Schema.Types.ObjectId, ref: 'Comment' }],
tagList: [{ type: String }], tagList: [{ type: String }],
author: { type: mongoose.Schema.Types.ObjectId, ref: 'User' } author: { type: mongoose.Schema.Types.ObjectId, ref: 'User' }
}, {timestamps: true, usepPushEach: true}); }, {timestamps: true, usePushEach: true});
ArticleSchema.plugin(uniqueValidator, {message: 'is already taken'}); ArticleSchema.plugin(uniqueValidator, {message: 'is already taken'});
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment