From 78d5e7507fcf60bf5bce649899656a245eb53820 Mon Sep 17 00:00:00 2001 From: Nikola Petrov Date: Tue, 16 Jul 2024 22:24:55 +0200 Subject: [PATCH] remove mongoose --- app.ts | 8 -------- package.json | 1 - 2 files changed, 9 deletions(-) diff --git a/app.ts b/app.ts index fca2c21..60a7002 100644 --- a/app.ts +++ b/app.ts @@ -5,14 +5,6 @@ import morgan from 'morgan' const hostname = '127.0.0.1'; const httpPort = 4080; -var mongoose = require('mongoose'); -var mongoDB = "mongodb://127.0.0.1/my_database"; -mongoose.connect(mongoDB); -mongoose.set('strictQuery', false); -mongoose.Promise = global.Promise; -var db = mongoose.connection; -db.on('error', console.error.bind(console, 'MongoDB connection error:')); - const app = express(); app.set('views', path.join(__dirname, 'views')); diff --git a/package.json b/package.json index 55feed8..ff61ff6 100644 --- a/package.json +++ b/package.json @@ -11,7 +11,6 @@ "@types/morgan": "^1.9.9", "express": "^4.18.2", "hbs": "^4.2.0", - "mongoose": "^7.5.2", "morgan": "~1.9.1", "mysql2": "^3.10.3" }