-1
var schema = new Schema({
firstName: {type: String, required: true},
lastName: {type: String, required: true},
password: {type: String, required: true},
email: {type: String, required: true, unique: true},
polls: [{type: Schema.Types.ObjectId, ref: 'Poll'}]
/*This is incorrect*/votes: [{{type: Schema.Types.ObjectId, ref: 'Poll'},{type: number}}]
});
,那麼請閱讀[詢問]如何在該機構中添加一些有意義的內容,而不是濫用標記,只是將標題複製到問題中。 – CodeCaster
@CodeCaster嗯,我不知道還有什麼可說的:/這只是一個語法問題。 – Coder1000