start of comments view
This commit is contained in:
@@ -2,10 +2,23 @@ var mongoose = require('mongoose');
|
||||
var secrets = require('../config/secrets');
|
||||
|
||||
var commentSchema = new mongoose.Schema({
|
||||
rank: { type: Number, default: -Infinity },
|
||||
upVotes: { type: Array, default: [] },
|
||||
associatedPost: {
|
||||
type: String,
|
||||
required: true
|
||||
},
|
||||
rank: {
|
||||
type: Number,
|
||||
default: -Infinity
|
||||
},
|
||||
upVotes: {
|
||||
type: Array,
|
||||
default: []
|
||||
},
|
||||
author: {},
|
||||
comments: { type: Array, default: [] }
|
||||
comments: {
|
||||
type: Array,
|
||||
default: []
|
||||
}
|
||||
});
|
||||
|
||||
module.exports = mongoose.model('Comment', commentSchema);
|
Reference in New Issue
Block a user