implemented comments

This commit is contained in:
Sheen Capadngan
2023-05-03 18:58:32 +08:00
parent dfb84e9932
commit f703ee29e5
16 changed files with 247 additions and 151 deletions
+6 -1
View File
@@ -1,9 +1,13 @@
import { Schema, model, Types, Document } from 'mongoose';
export enum AuthProvider {
GOOGLE = 'google',
}
export interface IUser extends Document {
_id: Types.ObjectId;
authId?: string;
authProvider?: string;
authProvider?: AuthProvider;
email: string;
firstName?: string;
lastName?: string;
@@ -33,6 +37,7 @@ const userSchema = new Schema<IUser>(
},
authProvider: {
type: String,
enum: AuthProvider,
},
email: {
type: String,