Refactored code, added user email preference selector