handle invitations