CSE316/hw4/server/models/top5list-model.js

14 lines
357 B
JavaScript
Raw Permalink Normal View History

2022-05-23 06:22:34 -04:00
const mongoose = require('mongoose')
const Schema = mongoose.Schema
const Top5ListSchema = new Schema(
{
name: { type: String, required: true },
items: { type: [String], required: true },
ownerEmail: { type: String, require: true }
},
{ timestamps: true },
)
module.exports = mongoose.model('Top5List', Top5ListSchema)