Add statement to fileLink to ignore href code when no fileLink.

This commit is contained in:
Mateusz Lerczak 2019-06-12 12:36:09 +02:00
parent c45c6e50e1
commit b9eab42823
No known key found for this signature in database
GPG Key ID: 963F5A9AABAB544A

View File

@ -557,10 +557,13 @@ class TextDescriptor extends Descriptor
}
$fileLink = $this->fileLinkFormatter->format($r->getFileName(), $r->getStartLine());
if ($fileLink) {
return sprintf('<href=%s>%s</>', $fileLink, $anchorText);
}
return $anchorText;
}
private function formatCallable($callable): string
{
if (\is_array($callable)) {