added mailer functionality, and linked the invite button to a send email method