mirror of
https://github.com/Litlyx/litlyx
synced 2025-12-09 23:48:36 +01:00
19 lines
435 B
TypeScript
19 lines
435 B
TypeScript
import { model, Schema, Types } from 'mongoose';
|
|
|
|
export type TRegister = {
|
|
email: string,
|
|
password: string,
|
|
code: string,
|
|
created_at: Date
|
|
}
|
|
|
|
const RegisterSchema = new Schema<TRegister>({
|
|
email: { type: String },
|
|
password: { type: String },
|
|
code: { type: String },
|
|
created_at: { type: Date, default: () => Date.now() }
|
|
});
|
|
|
|
export const RegisterModel = model<TRegister>('registers', RegisterSchema);
|
|
|