package and depencies

This commit is contained in:
RafficMohammed
2023-01-08 02:57:24 +05:30
parent d5332eb421
commit 1d54b8bc7f
4309 changed files with 193331 additions and 172289 deletions

View File

@@ -47,9 +47,7 @@ class StreamOutput extends Output
$this->stream = $stream;
if (null === $decorated) {
$decorated = $this->hasColorSupport();
}
$decorated ??= $this->hasColorSupport();
parent::__construct($verbosity, $decorated, $formatter);
}
@@ -64,9 +62,6 @@ class StreamOutput extends Output
return $this->stream;
}
/**
* {@inheritdoc}
*/
protected function doWrite(string $message, bool $newline)
{
if ($newline) {
@@ -91,7 +86,7 @@ class StreamOutput extends Output
*
* @return bool true if the stream supports colorization, false otherwise
*/
protected function hasColorSupport()
protected function hasColorSupport(): bool
{
// Follow https://no-color.org/
if (isset($_SERVER['NO_COLOR']) || false !== getenv('NO_COLOR')) {