Skip to content

Commit

Permalink
update server.js
Browse files Browse the repository at this point in the history
  • Loading branch information
mar4r8k-femi committed Jun 30, 2024
1 parent 82bef62 commit e6d7e03
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions server.js
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,9 @@ app.use("/api/products", (req, res) => {
})
});

// MongoDB connection
const client = new MongoClient(config.mongoURI, { useNewUrlParser: true, useUnifiedTopology: true });

// Get other database and collection
const database = client.db('sample_mflix');
const collection = database.collection('movies');
Expand Down

0 comments on commit e6d7e03

Please sign in to comment.