Skip to content

Commit

Permalink
fix(rstream): unsubscribe on error in transduce()
Browse files Browse the repository at this point in the history
  • Loading branch information
andrew8er committed Jun 28, 2018
1 parent 576f1da commit 8c7d937
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions packages/rstream/src/subs/transduce.ts
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ export function transduce<A, B, C>(src: Subscription<any, A>, tx: Transducer<A,
resolve(acc);
},
error(e) {
sub.unsubscribe();
reject(e);
}
}, tx);
Expand Down

0 comments on commit 8c7d937

Please sign in to comment.