Skip to content

Commit 383277b

Browse files
committed
Add note about cancellation of promise collections
1 parent dc42aa0 commit 383277b

1 file changed

Lines changed: 5 additions & 0 deletions

File tree

README.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -446,6 +446,11 @@ $promise->then(function ($value) {
446446
Useful functions for creating, joining, mapping and reducing collections of
447447
promises.
448448

449+
All functions working on promise collections (like `all()`, `race()`, `some()`
450+
etc.) support cancellation. This means, if you call `cancel()` on the returned
451+
promise, all promises in the collection are cancelled. If the collection itself
452+
is a promise which resolves to an array, this promise is also cancelled.
453+
449454
#### resolve()
450455

451456
```php

0 commit comments

Comments
 (0)