updated hasRoleOnProject and can functions