Closed Sarthak027 closed 3 months ago
Also remove the dbConnect() method from server.js file, now we don't need it.
Hey @Sarthak027, I have added the required changes that needs to be done. After these changes we are good to Merge this PR.
@Sarthak027 is attempting to deploy a commit to the Abhijeet's projects Team on Vercel.
A member of the Team first needs to authorize it.
Hey @abhijeetnishal can you please add the lable Gssoc'24 in this issuer!!
Hey @abhijeetnishal can you please add the lable Gssoc'24 in this issuer!!
Hey @Sarthak027 l, I have linked the issue where I have added labels.
Task completed
[X] Modify the existing code to connect to the MongoDB database only when a request is received that requires database access.
[X] Ensure that the database connection is closed when it is no longer needed to conserve resources.
[X] Implement a mechanism to handle errors that may occur when connecting to the database lazily.
This PR solves issue #18