Skip to content

Commit

Permalink
Fix: Undefined constant "Nextras\Migrations\Printers\STDOUT"
Browse files Browse the repository at this point in the history
  • Loading branch information
radimvaculik authored and JanTvrdik committed Jan 25, 2024
1 parent 6957593 commit c1a201d
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/Printers/Console.php
Original file line number Diff line number Diff line change
Expand Up @@ -105,8 +105,8 @@ protected function colorize(string $s, ?string $color): string
*/
protected function detectColorSupport(): bool
{
return (function_exists('posix_isatty') && posix_isatty(STDOUT))
return defined('STDOUT') && ((function_exists('posix_isatty') && posix_isatty(STDOUT))
|| (function_exists('stream_isatty') && stream_isatty(STDOUT))
|| (function_exists('sapi_windows_vt100_support') && sapi_windows_vt100_support(STDOUT));
|| (function_exists('sapi_windows_vt100_support') && sapi_windows_vt100_support(STDOUT)));
}
}

0 comments on commit c1a201d

Please sign in to comment.