reactphp / promise

Promises/A implementation for PHP.
https://reactphp.org/promise/
MIT License
2.38k stars 146 forks source link

some() implementation #245

Closed BitpostNetwork closed 1 year ago

BitpostNetwork commented 1 year ago

Adds a function some() that resolves similarly to all(), but continues to run despite rejecting any of the promises. A new promise is rejected only when all of the promises are rejected.

SimonFrings commented 1 year ago

@BitpostNetwork Thanks for filing this PR, we're always happy about contributions :+1:

Can you also add tests so we can assure that your suggested function works as expected.