From 9c7c637f8af8546df031dad07fd6579c194a9345 Mon Sep 17 00:00:00 2001 From: Juliette <663378+jrfnl@users.noreply.github.com> Date: Mon, 3 Oct 2022 16:09:09 +0200 Subject: [PATCH] PHP 8.2 | Fix deprecated embedded variables in text strings (#44538) PHP 8.2 will deprecate two of the four currently supported syntaxes for embedding variables in double quoted text string/heredocs. This library contains six uses of embedded variables using braces after the dollar sign (`"${foo}"`), which is one of the deprecated forms. This commit fixes all six. Refs: * https://wiki.php.net/rfc/deprecate_dollar_brace_string_interpolation Co-authored-by: jrfnl --- lib/compat/wordpress-6.1/class-wp-theme-json-6-1.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/compat/wordpress-6.1/class-wp-theme-json-6-1.php b/lib/compat/wordpress-6.1/class-wp-theme-json-6-1.php index ac2a8f9740e46a..2a3af5e903d7a3 100644 --- a/lib/compat/wordpress-6.1/class-wp-theme-json-6-1.php +++ b/lib/compat/wordpress-6.1/class-wp-theme-json-6-1.php @@ -1060,7 +1060,7 @@ protected static function get_property_value( $styles, $path, $theme_json = null if ( is_array( $ref_value ) && array_key_exists( 'ref', $ref_value ) ) { $path_string = json_encode( $path ); $ref_value_string = json_encode( $ref_value ); - _doing_it_wrong( 'get_property_value', "Your theme.json file uses a dynamic value (${ref_value_string}) for the path at ${path_string}. However, the value at ${path_string} is also a dynamic value (pointing to ${ref_value['ref']}) and pointing to another dynamic value is not supported. Please update ${path_string} to point directly to ${ref_value['ref']}.", '6.1.0' ); + _doing_it_wrong( 'get_property_value', "Your theme.json file uses a dynamic value ({$ref_value_string}) for the path at {$path_string}. However, the value at {$path_string} is also a dynamic value (pointing to {$ref_value['ref']}) and pointing to another dynamic value is not supported. Please update {$path_string} to point directly to {$ref_value['ref']}.", '6.1.0' ); } }