Commit 9cf83d9
Haider
stdin: use optional chaining for process.stdin NPE guard
Matches the literal form suryaiyer95 proposed in review #3 on PR #935:
`process.stdin?.isTTY` instead of an early-return + plain access.
Functionally equivalent — the fstat try/catch already returns "" when
fd 0 isn't open, so the optional chaining alone covers the embedded-
runtime case.1 parent 7fceb85 commit 9cf83d9
1 file changed
Lines changed: 4 additions & 4 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
77 | 77 | | |
78 | 78 | | |
79 | 79 | | |
80 | | - | |
81 | | - | |
82 | | - | |
83 | | - | |
| 80 | + | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
84 | 84 | | |
85 | 85 | | |
86 | 86 | | |
| |||
0 commit comments