def METHOD_NAME(self, entity_ids):
    self.entities_out = []
    for entity_id in entity_ids:
        entity = Entity.get(entity_id)
        if entity is not None:
            self.entities_out.append(entity)
    self.save()