From 5051452846348f5d2fb77ca7a66aa340b5ef14ce Mon Sep 17 00:00:00 2001 From: Nicolas Grekas Date: Tue, 13 Aug 2024 15:55:12 +0200 Subject: [PATCH] [PhpUnitBridge][Console][VarDumper] Fix handling NO_COLOR env var --- Dumper/CliDumper.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Dumper/CliDumper.php b/Dumper/CliDumper.php index 359171b..da1d5b2 100644 --- a/Dumper/CliDumper.php +++ b/Dumper/CliDumper.php @@ -606,7 +606,7 @@ private function hasColorSupport($stream): bool } // Follow https://no-color.org/ - if ('' !== ($_SERVER['NO_COLOR'] ?? getenv('NO_COLOR') ?: '')) { + if ('' !== (($_SERVER['NO_COLOR'] ?? getenv('NO_COLOR'))[0] ?? '')) { return false; }