function RequireMultiLineCallSniff::shouldReportError
1 call to RequireMultiLineCallSniff::shouldReportError()
- RequireMultiLineCallSniff::process in vendor/
slevomat/ coding-standard/ SlevomatCodingStandard/ Sniffs/ Functions/ RequireMultiLineCallSniff.php - * @phpcsSuppress SlevomatCodingStandard.TypeHints.ParameterTypeHint.MissingNativeTypeHint *
File
-
vendor/
slevomat/ coding-standard/ SlevomatCodingStandard/ Sniffs/ Functions/ RequireMultiLineCallSniff.php, line 220
Class
Namespace
SlevomatCodingStandard\Sniffs\FunctionsCode
private function shouldReportError(int $lineLength, string $lineStart, string $lineEnd, int $parametersCount, int $indentationLength) : bool {
if ($this->minLineLength === 0) {
return true;
}
if ($lineLength < $this->minLineLength) {
return false;
}
if ($parametersCount > 1) {
return true;
}
return strlen(trim($lineStart) . trim($lineEnd)) > $indentationLength;
}