You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
17 lines
510 B
17 lines
510 B
// email-verify.js
|
|
// Copyright (C) 2024 DTP Technologies, LLC
|
|
// All Rights Reserved
|
|
|
|
'use strict';
|
|
|
|
import mongoose from "mongoose";
|
|
const Schema = mongoose.Schema;
|
|
|
|
const EmailVerifySchema = new Schema({
|
|
created: { type: Date, default: Date.now, required: true, index: -1, expires: '30d' },
|
|
verified: { type: Date },
|
|
user: { type: Schema.ObjectId, required: true, index: 1, ref: 'User' },
|
|
token: { type: String, required: true },
|
|
});
|
|
|
|
export default mongoose.model('EmailVerify', EmailVerifySchema);
|