aboutsummaryrefslogtreecommitdiff
path: root/models/user.js
blob: 3751aae12a749024e9bb302911f8b525d4e5cf32 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
const mongoose = require('mongoose');

const userSchema = new mongoose.Schema({
  firstname: {type: String, required: true},
  lastname: {type: String, required: true},
  email: {type: String, required: true},
  password: {type: String, required: true},
});

const userModel = new mongoose.model('user', userSchema);

module.exports = userModel;