Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use Promise.all to execute multiple queries in parallel and $pull to remove field in cancelMembershipRequest.ts #1315

Closed
nishant3721 opened this issue Apr 19, 2023 · 1 comment · Fixed by #1316
Assignees
Labels
bug Something isn't working

Comments

@nishant3721
Copy link
Contributor

Describe the bug

  • Instead of executing each database query sequentially, you can execute them in parallel using Promise.all. This can significantly reduce the total execution time of the function.
  • Use $pull to remove the fields

To Reproduce
Steps to reproduce the behavior:

  1. start the server locally using the command 'npm run dev'
  2. run the query for cancelMembershipRequest

Expected behavior
NA

Actual behavior
NA

Screenshots
Not required

Additional details
Not required

Potential internship candidates
Please read this if you are planning to apply for a Palisadoes Foundation internship PalisadoesFoundation/talawa#359

@nishant3721 nishant3721 added the bug Something isn't working label Apr 19, 2023
@nishant3721
Copy link
Contributor Author

@palisadoes I would like to work on this issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants