Automattic / wp-memcached

Memcached Object Cache for WordPress.
https://wordpress.org/plugins/memcached/
GNU General Public License v2.0
157 stars 55 forks source link

PHP 8.2: Fix Creation of dynamic property deprecation notices #153

Closed philipjohn closed 2 months ago

philipjohn commented 10 months ago

In PHP 8.2, dynamically setting object properties that haven't been defined has been deprecated. WP_Object_Cache does this in several places, leading to a number of these notices.

The solution is simple - we simply need to define those properties in the class.

davidwren-boxuk commented 10 months ago

Would be great to see this merged if possible to reduce a lot of chatter in the logs!

Krinkle commented 4 months ago

A different PR that fixes the same issue has since been merged: https://github.com/Automattic/wp-memcached/pull/149

dd32 commented 2 months ago

Thanks for the PR @philipjohn, I apologise for the delay in feedback. It looks like these changes were merged in #149 and will be included in the 4.1 release via #162