Skip to content

Fix swapped closure parameters #1974

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

Merged
merged 1 commit into from
Jul 12, 2025
Merged

Fix swapped closure parameters #1974

merged 1 commit into from
Jul 12, 2025

Conversation

Kissaki
Copy link
Contributor

@Kissaki Kissaki commented Jul 12, 2025

As per reduce command documentation examples, the reduce closure has parameters |it, acc|.

This accidental swap was part of the introduction of the example in #1928.

As per [`reduce` command documentation examples][reduce], the reduce closure has parameters `|it, acc|`.

This accidental swap was part of the introduction of the example in nushell#1928.

[reduce]: https://www.nushell.sh/commands/docs/reduce.html
@fdncred fdncred merged commit f5f5fb7 into nushell:main Jul 12, 2025
2 checks passed
@fdncred
Copy link
Contributor

fdncred commented Jul 12, 2025

Good catch. Thanks

@Kissaki Kissaki mentioned this pull request Jul 12, 2025
@Kissaki Kissaki deleted the patch-5 branch July 12, 2025 20:00
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