Fix TransformOptions' callback (#43711)

Make it usable in object mode

Co-authored-by: jblaise <8171322+jblaise@users.noreply.github.com>
This commit is contained in:
jb 2020-04-13 20:54:11 +02:00 committed by GitHub
parent ebd96572dd
commit c9f36a9e0c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 3 additions and 3 deletions

View File

@ -3864,7 +3864,7 @@ declare module "stream" {
}
export interface TransformOptions extends DuplexOptions {
transform?: (chunk: string | Buffer, encoding: string, callback: Function) => any;
transform?: (chunk: any, encoding: string, callback: Function) => any;
flush?: (callback: Function) => any;
}

View File

@ -3914,7 +3914,7 @@ declare module "stream" {
}
export interface TransformOptions extends DuplexOptions {
transform?: (chunk: string | Buffer, encoding: string, callback: Function) => any;
transform?: (chunk: any, encoding: string, callback: Function) => any;
flush?: (callback: Function) => any;
}

View File

@ -5615,7 +5615,7 @@ declare module "stream" {
}
export interface TransformOptions extends DuplexOptions {
transform?: (chunk: string | Buffer, encoding: string, callback: Function) => any;
transform?: (chunk: any, encoding: string, callback: Function) => any;
flush?: (callback: Function) => any;
}