diff options
author | Nayeem Rahman <nayeemrmn99@gmail.com> | 2020-06-27 12:44:02 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-06-27 13:44:02 +0200 |
commit | d77a55a97371f75eeabe39f4f051013029926839 (patch) | |
tree | 045d155e20e0033801e06e86f4ac4c8e587ae1df /cli/js/lib.deno.ns.d.ts | |
parent | affba804546607c0d26887bb5c40cba9c9be3fe6 (diff) |
fix(cli/js/process): Fix conditional types for process sockets (#6275)
Diffstat (limited to 'cli/js/lib.deno.ns.d.ts')
-rw-r--r-- | cli/js/lib.deno.ns.d.ts | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/cli/js/lib.deno.ns.d.ts b/cli/js/lib.deno.ns.d.ts index f9438ed9c..f3ee04243 100644 --- a/cli/js/lib.deno.ns.d.ts +++ b/cli/js/lib.deno.ns.d.ts @@ -1779,9 +1779,15 @@ declare namespace Deno { export class Process<T extends RunOptions = RunOptions> { readonly rid: number; readonly pid: number; - readonly stdin: T["stdin"] extends "piped" ? Writer & Closer : null; - readonly stdout: T["stdout"] extends "piped" ? Reader & Closer : null; - readonly stderr: T["stderr"] extends "piped" ? Reader & Closer : null; + readonly stdin: T["stdin"] extends "piped" + ? Writer & Closer + : (Writer & Closer) | null; + readonly stdout: T["stdout"] extends "piped" + ? Reader & Closer + : (Writer & Closer) | null; + readonly stderr: T["stderr"] extends "piped" + ? Reader & Closer + : (Writer & Closer) | null; /** Resolves to the current status of the process. */ status(): Promise<ProcessStatus>; /** Buffer the stdout until EOF and return it as `Uint8Array`. |