Locker\Repository\Statement\EloquentLinker::updateReferences PHP Method

updateReferences() public method

Updates statement references.
public updateReferences ( array $statements, StoreOptions $opts )
$statements array
$opts StoreOptions
    public function updateReferences(array $statements, StoreOptions $opts)
    {
        $this->voider = strpos(json_encode($statements), 'voided') !== false;
        $this->downed = new Collection();
        $this->to_update = $this->getModels($statements, $opts);
        $statement_ids = array_map(function ($statement) {
            return $statement->id;
        }, $statements);
        $this->upRefStatements = $this->eagerLoadUpRefs($statement_ids, $opts);
        while (count($this->to_update) > 0) {
            $this->upLink($this->to_update[0], [], $opts, true);
        }
    }