constraints: replace get_common_relationship() with get_shared_relations()