function any in Lockr 7.3
Like some(), with 1 as count. However, if the promise fulfills, the fulfillment value is not an array of 1 but the value directly.
Parameters
mixed $promises Promises or values.:
Return value
File
- vendor/
guzzlehttp/ promises/ src/ functions.php, line 293
Namespace
GuzzleHttp\PromiseCode
function any($promises) {
return some(1, $promises)
->then(function ($values) {
return $values[0];
});
}