invite user functionality

Invite user functionality is now working.