Added code to filter the db based on the email metadata