1
0
Fork 0

To enable to the TransportException code to be accessed in PHP < 8.1, make reflection property accessible (#11974)

pull/11962/merge
Sam B 2024-05-21 21:45:37 +01:00 committed by GitHub
parent 8d90eb694a
commit d4b071bd1e
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 1 additions and 0 deletions

View File

@ -446,6 +446,7 @@ class Application extends BaseApplication
// as http error codes are all beyond the 255 range of permitted exit codes // as http error codes are all beyond the 255 range of permitted exit codes
if ($e instanceof TransportException) { if ($e instanceof TransportException) {
$reflProp = new \ReflectionProperty($e, 'code'); $reflProp = new \ReflectionProperty($e, 'code');
$reflProp->setAccessible(true);
$reflProp->setValue($e, Installer::ERROR_TRANSPORT_EXCEPTION); $reflProp->setValue($e, Installer::ERROR_TRANSPORT_EXCEPTION);
} }