Skip to content

Commit

Permalink
refresh
Browse files Browse the repository at this point in the history
  • Loading branch information
jipsonminibhavan committed Jan 25, 2024
1 parent a2ba702 commit 2000190
Showing 1 changed file with 2 additions and 6 deletions.
8 changes: 2 additions & 6 deletions backend/src/db.ts
Original file line number Diff line number Diff line change
@@ -1,14 +1,10 @@
import mongoose, { ConnectOptions, startSession } from "mongoose";
import mongoose from "mongoose";
import { PORT, MONGODB_URI, API_VERSION } from "./config";
import { Status } from "./models/Status";

const connectToDB = async () => {
try {
const instance = await mongoose.connect(MONGODB_URI, {
useNewUrlParser: true,
useUnifiedTopology: true,
autoIndex: true,
} as ConnectOptions);
const instance = await mongoose.connect(MONGODB_URI);
console.log("Connected to MongoDB");

const status = new Status({ db: true, version: "1.0.0" });
Expand Down

0 comments on commit 2000190

Please sign in to comment.