From 85447be8855d7890dea457a4562dfb148e368bd5 Mon Sep 17 00:00:00 2001 From: Derrick Hammer Date: Mon, 5 Sep 2022 06:26:20 -0400 Subject: [PATCH] *Bug fix first promise in result which returns just an ErrTuple --- src/index.ts | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/index.ts b/src/index.ts index eb42e7e..247d5be 100644 --- a/src/index.ts +++ b/src/index.ts @@ -281,10 +281,8 @@ export class StreamingRpcQuery extends SimpleRpcQuery { get result(): Promise { return (this._promise as Promise) - .then( - (result): [sendUpdate: DataFn, response: Promise] => result[1] - ) - .then((response: any) => { + .then((result): Promise => result) + .then((response: ErrTuple) => { if (response[1]) { return { error: response[1] }; }