Skip to content

PHP 8.2 Deprecation: Fix creation of dynamic property.#413

Merged
danielbachhuber merged 1 commit intowp-cli:mainfrom
Soean:php-82-fix
Jul 13, 2023
Merged

PHP 8.2 Deprecation: Fix creation of dynamic property.#413
danielbachhuber merged 1 commit intowp-cli:mainfrom
Soean:php-82-fix

Conversation

@Soean
Copy link
Contributor

@Soean Soean commented Jul 13, 2023

If I use WP CLI 2.8.1 with PHP 8.2.7 and call wp site list, I get a PHP deprecation message:

Deprecated: Creation of dynamic property Site_Command::$fetcher is deprecated in phar:///usr/local/bin/wp/vendor/wp-cli/entity-command/src/Site_Command.php on line 37

This PR adds properties to all classes with a fetcher.

@Soean Soean requested a review from a team as a code owner July 13, 2023 13:54
Copy link
Member

@swissspidy swissspidy left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you!

@swissspidy swissspidy added this to the 2.5.3 milestone Jul 13, 2023
@swissspidy swissspidy added command:user Related to 'user' command command:post Related to 'post' command command:site Related to 'site' command command:comment Related to 'comment' command labels Jul 13, 2023
@danielbachhuber danielbachhuber merged commit ab52304 into wp-cli:main Jul 13, 2023
@Soean Soean deleted the php-82-fix branch July 14, 2023 06:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

command:comment Related to 'comment' command command:post Related to 'post' command command:site Related to 'site' command command:user Related to 'user' command

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants