Thanks to visit codestin.com
Credit goes to github.com

Skip to content

fix: sumBy returns boolean instead of number when summing booleans #5985 #5986

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

Open
wants to merge 4 commits into
base: main
Choose a base branch
from

Conversation

johnmasonyxe
Copy link

@johnmasonyxe johnmasonyxe commented Apr 25, 2025

problem

  • _.sumBy called with a single boolean element returns boolean a instead of number

solution

  • coerce boolean to number for the base case

notes & links

@johnmasonyxe johnmasonyxe changed the title Fix sum by returning boolean fix sumBy returning boolean Apr 25, 2025
@johnmasonyxe johnmasonyxe changed the title fix sumBy returning boolean fix sumBy returning boolean Apr 25, 2025
@johnmasonyxe johnmasonyxe changed the title fix sumBy returning boolean fix: sumBy returns boolean instead of number when summing booleans #5985 Apr 25, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

1 participant