Progress with authentication tolen
This commit is contained in:
21
server/src/models/user.js
Normal file
21
server/src/models/user.js
Normal file
@@ -0,0 +1,21 @@
|
||||
import mongoose from 'mongoose';
|
||||
const Schema = mongoose.Schema;
|
||||
const UserSchema = new Schema({
|
||||
username: {
|
||||
type: String,
|
||||
required: true
|
||||
},
|
||||
email: {
|
||||
type: String,
|
||||
required: true
|
||||
},
|
||||
password: {
|
||||
type: String,
|
||||
required: true
|
||||
},
|
||||
deleted: {
|
||||
type: Boolean,
|
||||
required: false
|
||||
}
|
||||
});
|
||||
export default mongoose.model('user', UserSchema);
|
||||
Reference in New Issue
Block a user