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

Resolve Promise\all immediately for empty array #50

Merged
merged 1 commit into from
Jun 10, 2017

Conversation

sunverwerth
Copy link
Contributor

@sunverwerth sunverwerth commented Jun 9, 2017

According to https://developer.mozilla.org/en/docs/Web/JavaScript/Reference/Global_Objects/Promise/all

Promise.all()called with an empty array should resolve synchronously and immediately.

Before this PR it would create a promise that never gets resolved.

@staabm staabm merged commit 0ceba38 into sabre-io:master Jun 10, 2017
@staabm
Copy link
Member

staabm commented Jun 10, 2017

released with 5.0.2 which also includes some perf. improvements.

https://github.com/fruux/sabre-event/releases/tag/5.0.2

@staabm staabm added the bug label Jun 10, 2017
@sunverwerth sunverwerth deleted the fix-promise-all-empty-array branch June 10, 2017 09:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants