Skip to content

Commit

Permalink
Update index.js
Browse files Browse the repository at this point in the history
  • Loading branch information
PumuduRajakaruna authored Jan 6, 2024
1 parent 9ddfa1a commit 811c05f
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions code/server/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ var io=require("socket.io")(server);
app.use(express.json());

// database
const DB="mongodb+srv://namal:qazxnmlp@cluster0.jovzlek.mongodb.net/?retryWrites=true&w=majority";
const DB="mongodb+srv://<userName>:<password>@cluster0.jovzlek.mongodb.net/?retryWrites=true&w=majority";
mongoose.connect(DB).then(()=>{
console.log("DB connection established");
}).catch(err => console.log(err) );
Expand Down Expand Up @@ -82,4 +82,4 @@ io.on("connection",(socket)=>{

server.listen(port, "0.0.0.0", () => {
console.log("udaya " +port);
});
});

0 comments on commit 811c05f

Please sign in to comment.