

def _is_in_association(self, obj_id):
    if (not obj_id):
        raise BadRequest('Must provide object id')
    assoc_ids = self.find_associations(anyside=obj_id, id_only=True, limit=1)
    if assoc_ids:
        log.debug('_is_in_association(%s): Object has associations: %s', obj_id, assoc_ids)
        return True
    return False

dataset/ETHPy150Open ooici/pyon/pyon/ion/resregistry.py ResourceRegistry._is_in_association/original