Made relations respect visible attributes.