Skip to content

Commit 0259f01

Browse files
neclimdulnicolas-grekas
authored andcommitted
Silence isatty warnings during tty detection
1 parent 32ba2ac commit 0259f01

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

Helper/QuestionHelper.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -485,11 +485,11 @@ private function isInteractiveInput($inputStream): bool
485485
}
486486

487487
if (\function_exists('stream_isatty')) {
488-
return self::$stdinIsInteractive = stream_isatty(fopen('php://stdin', 'r'));
488+
return self::$stdinIsInteractive = @stream_isatty(fopen('php://stdin', 'r'));
489489
}
490490

491491
if (\function_exists('posix_isatty')) {
492-
return self::$stdinIsInteractive = posix_isatty(fopen('php://stdin', 'r'));
492+
return self::$stdinIsInteractive = @posix_isatty(fopen('php://stdin', 'r'));
493493
}
494494

495495
if (!\function_exists('exec')) {

0 commit comments

Comments
 (0)