mirror of
https://github.com/Akif9748/akf-forum.git
synced 2024-11-23 04:10:40 +03:00
8 lines
274 B
JavaScript
8 lines
274 B
JavaScript
const mongoose = require("mongoose");
|
|
require("dotenv").config();
|
|
|
|
mongoose.connect(process.env.MONGO_DB_URL, () => console.log("Database is connected"));
|
|
|
|
const Models = require("../models");
|
|
|
|
Object.values(Models).forEach(model => model.deleteMany({}).then(console.log));
|