Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- let mongoose = require('mongoose');
- let UserSchema = new mongoose.Schema({
- _id: mongoose.Schema.Types.ObjectId,
- firstname: String,
- lastname: String,
- username: { type: String, required: true, index: { unique: true } },
- password: { type: String},
- picture: String,
- lastlogin: Date,
- premium: Boolean,
- type: String
- });
- mongoose.model('User',UserSchema);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement