Formatted controller and fixed email sending