Google-Developer-Students-Club-DMCE / project-mgmt-api-hacktober2022

3 stars 10 forks source link

Issue https://github.com/Google-Developer-Students-Club-DMCE/project-mgmt-api-hacktober2022/issues/11: Created GET request to get a single project data #21

Closed Gowrishankar04 closed 2 years ago

devendra-dantal04 commented 2 years ago

1) Add these block of code in try block :

if(!project) {
 res.status(404).json({ success: false, message: "Project Not Found" });
}

2 ) Send the success response with {success : true} flag 3) In catch block, send the response with 500 status code 4) Destructure the req.params.id don't implement it directly

Gowrishankar04 commented 2 years ago

Hi @devendra-dantal04 ,

Updated the requested changes. Please check and merge.

Thanks