Use dependency injection to inject the database into the mailer service