public function perform($results) { $node_list = new NodeList([]); foreach ($results as $nodes) { $node_list->addNodeArray($nodes); } if ($node_list->containsNodeId($this->settings->own_node_id)) { $this->settings->own_node_id = Node::randomNodeId(); $this->find_node_task = new Bootstrap($this->settings, $this->bootstrap_nodes); $this->find_node_task->enqueue()->done([$this, 'emitSuccess']); } else { $this->emitSuccess($this->settings->own_node_id); } }