1
0
Fork 0

Use reactphp/promise v2 compatible code

pull/11795/head
Jordi Boggiano 2024-03-20 12:32:54 +01:00
parent 59152ad7aa
commit 75ccf6557a
No known key found for this signature in database
GPG Key ID: 7BBD42C429EC80BC
1 changed files with 2 additions and 2 deletions

View File

@ -496,7 +496,7 @@ class FileDownloader implements DownloaderInterface, ChangeReportInterface
}
$promise = $this->download($package, $targetDir.'_compare', null, false);
$promise->catch(function ($ex) use (&$e) {
$promise->then(null, function ($ex) use (&$e) {
$e = $ex;
});
$this->httpDownloader->wait();
@ -504,7 +504,7 @@ class FileDownloader implements DownloaderInterface, ChangeReportInterface
throw $e;
}
$promise = $this->install($package, $targetDir.'_compare', false);
$promise->catch(function ($ex) use (&$e) {
$promise->then(null, function ($ex) use (&$e) {
$e = $ex;
});
$this->process->wait();