Unused import
Use HTMLTemplates to send user email address confirm mail. Also, created log_event helper function