Fixed sending emails with attachments
Updated Mailer class to conform to updated interface