Fix email formatting

Based on sj26's pull request, but we added same fix to member settings page as well.