Closed Jai-Marothiya closed 10 months ago
Hi @narayan954,
Merge my pull request with the Hacktoberfest merge label.
Thanks.
Kudos, SonarCloud Quality Gate passed!
0 Bugs
0 Vulnerabilities
0 Security Hotspots
0 Code Smells
No Coverage information
0.0% Duplication
Fix the issue in deleting the comments: Basically when we delete the comment every time the last comment is deleted because when we use closure during the map it always takes the comment value that is the last one and always the last element it passes to deleteComment() function.
So I use one separate state that contains the id of a particular comment when it's deletion call.
that's a wonderful solution! thanks @Jai-Marothiya
please remember to mention issue number in prs. it helps a lot!
Fix the issue in deleting the comments: Basically when we delete the comment every time the last comment is deleted because when we use closure during the map it always takes the comment value that is the last one and always the last element it passes to deleteComment() function.
So I use one separate state that contains the id of a particular comment when it's deletion call.