Skip to content

Commit

Permalink
jest
Browse files Browse the repository at this point in the history
  • Loading branch information
Liza K committed Nov 22, 2020
1 parent e9103b7 commit 3fcac6e
Showing 1 changed file with 5 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,11 @@ export const createStreamingBatchedFunction = <Payload, Result extends object>(
resolve();
cleanup();
};
if (abortPromise) abortPromise.catch(onDone);
if (abortPromise)
abortPromise.catch(() => {
item.future.reject(new AbortError());
onDone();
});
item.future.promise.then(onDone, onDone);
});
});
Expand Down

0 comments on commit 3fcac6e

Please sign in to comment.