(fdNumber, value, optionName)
| 96 | // Since this is an edge case, we simply throw an error message. |
| 97 | // See https://github.com/sindresorhus/execa/pull/643#discussion_r1435905707 |
| 98 | const getStandardStream = (fdNumber, value, optionName) => { |
| 99 | const standardStream = STANDARD_STREAMS[fdNumber]; |
| 100 | |
| 101 | if (standardStream === undefined) { |
| 102 | throw new TypeError(`The \`${optionName}: ${value}\` option is invalid: no such standard stream.`); |
| 103 | } |
| 104 | |
| 105 | return standardStream; |
| 106 | }; |
no outgoing calls
no test coverage detected