refactoring invite friends and link to api user profile - 2