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

update Set values() and valuesLegacy() to return items values instead… #7

Merged
merged 1 commit into from
Jan 17, 2016

Conversation

wruth
Copy link
Contributor

@wruth wruth commented Jan 15, 2016

… of items keys

Hi Loiane. I'm enjoying your book! I'd like to suggest a modification to your Set implementation in chapter 6. Your values() method is really returning the keys to the items object. One consequence of this is that String values are being returned in the array, since JS coerced the numerical values to Strings in order to use them as keys in the items object. It might be better to return the actual numeric values? Hence my PR.

@loiane
Copy link
Owner

loiane commented Jan 17, 2016

Thanks for the PR!

loiane added a commit that referenced this pull request Jan 17, 2016
update Set values() and valuesLegacy() to return items values instead…
@loiane loiane merged commit 2966435 into loiane:second-edition Jan 17, 2016
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