mirror of
https://github.com/barryvdh/ReflectionDocBlock.git
synced 2026-08-18 01:57:13 +00:00
Merge pull request #288 from jrfnl/feature/docblock-source-phpstan-fix
DocBlock/Tags/Source: remove redundant code
This commit is contained in:
@@ -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
|
||||||
: '');
|
: '');
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user