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

fix: Suppress deprecation warnings in PHP 8.1 #1066

Merged
merged 1 commit into from
Dec 9, 2021
Merged

fix: Suppress deprecation warnings in PHP 8.1 #1066

merged 1 commit into from
Dec 9, 2021

Conversation

andreas-aeschlimann
Copy link
Contributor

In PHP 8.1, we need to add the mixed return type to the jsonSerialize implementation. The mixed return type is not supported in older versions. It is possible to suppress the deprecation warning by adding a PHP attribute. Older PHP versions will interpret attributes as a comment.

In PHP 8.1, we need to add the mixed return type to the jsonSerialize implementation. The mixed return type is not supported in older versions. It is possible to suppress the deprecation warning by adding a PHP attribute. Older PHP versions will interpret attributes as a comment.
@andreas-aeschlimann
Copy link
Contributor Author

@thinkingserious any chance this is going to be reviewed?

It's a very easy fix, backward compatible and will enable everyone to use SendGrid without errors on PHP 8.1.

@shwetha-manvinkurke shwetha-manvinkurke merged commit 5f8a25c into sendgrid:main Dec 9, 2021
@andreas-aeschlimann
Copy link
Contributor Author

Thanks!

@shwetha-manvinkurke shwetha-manvinkurke changed the title Suppress deprecation warnings in PHP 8.1 fix: Suppress deprecation warnings in PHP 8.1 Dec 15, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants