Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make it compatible with PHP 8.2 #110

Merged
merged 2 commits into from
Aug 7, 2024

Conversation

elias-playfinder
Copy link
Contributor

This prevent the deprecated error:

Creation of dynamic property OpenActive\\Validators\\RpdeEnumValidator::$classname is deprecated

@nickevansuk
Copy link
Contributor

Should 8.2 also be added to CI along with this?

https://github.com/elias-playfinder/models-php/blob/4689f4462b9993c5d4e3d42272bf1025891db341/.github/workflows/tests.yaml#L14

@drinkynet
Copy link
Contributor

@nickevansuk Here is some information on the PHP 8 Dynamic properties deprecation: https://php.watch/versions/8.2/dynamic-properties-deprecated

There are 3 options:

@nathansalter nathansalter self-assigned this May 24, 2024
@nathansalter
Copy link
Contributor

Fine with this to be merged but we do need to fix the CI builds first

@drinkynet
Copy link
Contributor

drinkynet commented May 24, 2024

If you want the 5.6 test to pass you'll need to change it to:

protected $classname;

type declarations for properties are 7.4+

@elias-playfinder
Copy link
Contributor Author

👍 Sure. I've changed and added the type as notation instead

@nathansalter nathansalter merged commit 96d1621 into openactive:master Aug 7, 2024
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: ✅ Done
Development

Successfully merging this pull request may close these issues.

4 participants