akf-forum/models/Secret.js
Akif9748 ae83e014a0 Mongoose is fixed & optimized
The dublicate key error fixed, ids as string.
classes removed. using mongoose's magic
2022-08-09 19:16:34 +03:00

12 lines
No EOL
230 B
JavaScript

const { Schema, model } = require("mongoose")
const schema = new Schema({
username: { type: String, unique: true },
password: String,
id: { type:String, unique: true }
});
module.exports = model('secret', schema);