mirror of
https://github.com/WordPress/WordPress.git
synced 2024-11-14 22:56:19 +01:00
6a19a16872
In each child class: renames the parameter to match the parent's method signature. Why? PHP 8 introduces the ability to pass named arguments to function/method calls. This means the child and parent method signatures (i.e. parameter names) need to match. Changes for readability: - `@since` clearly specifies the original parameter name and its new name as well as why the change happened. - In methods longer than a single line, the generic parameter is reassigned to the original parameter restoring it for context for use within the method. An inline comment is added to explain why this reassignment is made. Follow-up to [19995], [21037], [21053], [21354], [38829], [51298]. Props jrf, hellofromTonya, sergeybiryukov, azaozz, desrosj, johnbillion. See #51553. Built from https://develop.svn.wordpress.org/trunk@51784 git-svn-id: http://core.svn.wordpress.org/trunk@51391 1a063a9b-81f0-0310-95a4-ce76da25c4cd
29 lines
545 B
PHP
29 lines
545 B
PHP
<?php
|
|
/**
|
|
* Customize API: WP_Customize_Background_Image_Setting class
|
|
*
|
|
* @package WordPress
|
|
* @subpackage Customize
|
|
* @since 4.4.0
|
|
*/
|
|
|
|
/**
|
|
* Customizer Background Image Setting class.
|
|
*
|
|
* @since 3.4.0
|
|
*
|
|
* @see WP_Customize_Setting
|
|
*/
|
|
final class WP_Customize_Background_Image_Setting extends WP_Customize_Setting {
|
|
public $id = 'background_image_thumb';
|
|
|
|
/**
|
|
* @since 3.4.0
|
|
*
|
|
* @param mixed $value The value to update. Not used.
|
|
*/
|
|
public function update( $value ) {
|
|
remove_theme_mod( 'background_image_thumb' );
|
|
}
|
|
}
|