We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
//delete review route // app.delete( // "/listings/:id/reviews/:reviewId", // wrapAsync(async(req,res)=>{ // let {id , reviewId} = req.params;
// await Listing.findByIdAndDelete(id , {$pull : {reviews : reviewId}}); // await Review.findByIdAndDelete(reviewId);
// res.redirect(/listings/${id}); // }) // )
/listings/${id}
kindly bug it
The text was updated successfully, but these errors were encountered:
It will be await Listing.findByIdAndUpdate(id , {$pull : {reviews : reviewId}});
Sorry, something went wrong.
No branches or pull requests
//delete review route
// app.delete(
// "/listings/:id/reviews/:reviewId",
// wrapAsync(async(req,res)=>{
// let {id , reviewId} = req.params;
// await Listing.findByIdAndDelete(id , {$pull : {reviews : reviewId}});
// await Review.findByIdAndDelete(reviewId);
// res.redirect(
/listings/${id}
);// })
// )
kindly bug it
The text was updated successfully, but these errors were encountered: