georgeboot / laravel-echo-api-gateway

Use Laravel Echo with API Gateway Websockets. Works with Bref.sh and Laravel Vapor.
MIT License
99 stars 23 forks source link

0.1.2 Version is not compatible with PHP 7.4 | unexpected 'protected', expecting variable (T_VARIABLE) at /ConnectionRepository.php:13 #10

Open julianlaibach opened 3 years ago

julianlaibach commented 3 years ago

Hi @georgeboot, since the Constructor property promotion is only Available since PHP 8.x the Minor Update 0.1.2 is no longer compatible with PHP 7.x

I get the Following Error:

syntax error, unexpected 'protected' (T_PROTECTED), expecting variable (T_VARIABLE) {"exception":"[object] (ParseError(code: 0): syntax error, unexpected 'protected' (T_PROTECTED), expecting variable (T_VARIABLE) at /var/www/html/vendor/georgeboot/laravel-echo-api-gateway/src/ConnectionRepository.php:13)

Downgrading to Version 0.1.0 resolved this Issue for me running my App on PHP 7.4.

Thank you! :)

georgeboot commented 3 years ago

Yeah I also noticed that, apologies!

The dev-master has the correct requirements in thecomposer.json, so expect the next release to require PHP 8.

Any specific reasons you haven't upgraded yet? I could easily make the package support 7.4 as well, but kind of also like soft-forcing people to upgrade their PHP versions ;-)