Find references on unused symbol must not load referenced URIs
parent
f10680e441
commit
258b905d9f
|
@ -221,9 +221,11 @@ class TextDocument
|
|||
return [];
|
||||
}
|
||||
}
|
||||
$referenceUris = $this->index->getReferenceUris($fqn);
|
||||
if (!empty($referenceUris)) {
|
||||
$refDocuments = yield Promise\all(array_map(
|
||||
[$this->documentLoader, 'getOrLoad'],
|
||||
$this->index->getReferenceUris($fqn)
|
||||
$referenceUris
|
||||
));
|
||||
foreach ($refDocuments as $document) {
|
||||
$refs = $document->getReferenceNodesByFqn($fqn);
|
||||
|
@ -234,6 +236,7 @@ class TextDocument
|
|||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
return $locations;
|
||||
});
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue