Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Reduce code size #4

Merged
merged 1 commit into from
Aug 21, 2024
Merged

Reduce code size #4

merged 1 commit into from
Aug 21, 2024

Conversation

ehmicky
Copy link
Collaborator

@ehmicky ehmicky commented Aug 20, 2024

This PR removes some dead code.

return {
[Symbol.asyncIterator]: stream[Symbol.asyncIterator].bind(stream),
};
}
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not used.


export async function * combineAsyncIterables(iterable1, iterable2) {
const iterator1 = iterable1[Symbol.asyncIterator]();
const iterator2 = iterable2[Symbol.asyncIterator]();
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Node.js streams are both iterables and iterators.

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The function name is no longer correct then.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed. 👍

@ehmicky ehmicky requested a review from sindresorhus August 21, 2024 19:36
@sindresorhus sindresorhus merged commit 3525618 into main Aug 21, 2024
6 checks passed
@sindresorhus sindresorhus deleted the reduce-code-size branch August 21, 2024 20:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants