The film collection has a review array of objects which holds the userid who made the review:
The user collection has a filmsReviewed array of object storing all the films that user reviewed:

I want to delete a user which I know how to do but before I need to delete all the film reviews made by this user on films. I know how to perform the deletion of a review but don't know how to search for the films to be deleted within the films collection based on the filmReviewed array of objects in the User collection.
// search for all film reviews made by this user
//????????
// delete all film reviews made by this user for a specific film
await Film.findOneAndUpdate(
{_id:request.params.filmid},
{$pull:{reviews:{userid:mongoose.Types.ObjectId(request.body.userid)}}});
// delete the user
const opResult=await User.findByIdAndRemove(request.params.id);
Any ideas?