Merge pull request #288 from jrfnl/feature/docblock-source-phpstan-fix

DocBlock/Tags/Source: remove redundant code
This commit is contained in:
Jaap van Otterdijk
2021-08-06 11:57:03 +02:00
committed by GitHub
+3 -5
View File
@@ -104,14 +104,12 @@ final class Source extends BaseTag implements Factory\StaticMethod
$startingLine = (string) $this->startingLine; $startingLine = (string) $this->startingLine;
$lineCount = $this->lineCount !== null ? '' . $this->lineCount : ''; $lineCount = $this->lineCount !== null ? ' ' . $this->lineCount : '';
return $startingLine return $startingLine
. ($lineCount !== '' . $lineCount
? ($startingLine || $startingLine === '0' ? ' ' : '') . $lineCount
: '')
. ($description !== '' . ($description !== ''
? ($startingLine || $startingLine === '0' || $lineCount !== '' ? ' ' : '') . $description ? ' ' . $description
: ''); : '');
} }
} }