Skip to content

Commit

Permalink
Fix regression where wrong values were passed
Browse files Browse the repository at this point in the history
This fixes a regression where, when an output value was omitted,
then the initial, instead of the previous, value was passed to
the next iteration.
  • Loading branch information
wooorm committed Jun 25, 2021
1 parent c84b752 commit 281f0c1
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,9 @@ export function trough() {
}
}

// Save the newly created `output` for the next call.
values = output

// Next or done.
if (fn) {
wrap(fn, next)(...output)
Expand Down

0 comments on commit 281f0c1

Please sign in to comment.