avoid tables to have apparently long blank line breaks and be too far appart for long nested array params
This commit is contained in:
parent
ef3ae9cf45
commit
9d89f1e16a
@ -198,7 +198,17 @@ abstract class Descriptor implements DescriptorInterface
|
||||
protected function formatParameter($value)
|
||||
{
|
||||
if (is_bool($value) || is_array($value) || (null === $value)) {
|
||||
return json_encode($value);
|
||||
$jsonString = json_encode($value);
|
||||
|
||||
if (!function_exists('mb_strlen')) {
|
||||
return substr($jsonString, 0, 60).(strlen($jsonString) > 60 ? ' ...' : '');
|
||||
}
|
||||
|
||||
if (mb_strlen($jsonString) > 60) {
|
||||
return mb_substr($jsonString, 0, 60).' ...';
|
||||
}
|
||||
|
||||
return $jsonString;
|
||||
}
|
||||
|
||||
return (string) $value;
|
||||
|
Reference in New Issue
Block a user