diff --git a/ts/00_commitinfo_data.ts b/ts/00_commitinfo_data.ts index 6f7c3a1..eb9586a 100644 --- a/ts/00_commitinfo_data.ts +++ b/ts/00_commitinfo_data.ts @@ -3,6 +3,6 @@ */ export const commitinfo = { name: '@push.rocks/smartstream', - version: '3.0.6', + version: '3.0.7', description: 'simplifies access to node streams' } diff --git a/ts/smartstream.classes.passthrough.ts b/ts/smartstream.classes.passthrough.ts index db62c9c..202cc0a 100644 --- a/ts/smartstream.classes.passthrough.ts +++ b/ts/smartstream.classes.passthrough.ts @@ -13,7 +13,9 @@ export class PassThrough extends plugins.stream.Duplex { if (this.push(chunk, encoding)) { callback(); } else { - this.once('drain', callback); + this.once('drain', () => { + callback(); + }); } } } \ No newline at end of file