feat: add password login

This commit is contained in:
wancat committed 2023-09-11 22:59:41 +08:00
1 parent a5dbcd7db4
commit bcdd04715d
8 files changed
+390 -12

No files matched your search

+11 -3
View File
@@ -1,9 +1,17 @@
import { model } from 'mongoose'
const User = model('User', {
username: String,
password: String,
email: String,
username: {
type: String,
unique: true,
required: true,
},
email: {
type: String,
unique: true,
required: true,
},
hashedPassword: String,
})
export default User