Replace user.email with helper function (closes #294)