diff --git src/wp-includes/class-wp-customize-manager.php src/wp-includes/class-wp-customize-manager.php
index d047620..b4a01e6 100644
|
|
|
final class WP_Customize_Manager { |
| 2010 | 2010 | * previous saved settings and overriding the associated user_id if they made no change. |
| 2011 | 2011 | */ |
| 2012 | 2012 | $changed_setting_ids = array(); |
| | 2013 | $unchanged_incoming_setting_ids = array(); |
| 2013 | 2014 | foreach ( $post_values as $setting_id => $setting_value ) { |
| 2014 | 2015 | $setting = $this->get_setting( $setting_id ); |
| 2015 | 2016 | |
| … |
… |
final class WP_Customize_Manager { |
| 2028 | 2029 | ); |
| 2029 | 2030 | if ( $is_value_changed ) { |
| 2030 | 2031 | $changed_setting_ids[] = $setting_id; |
| | 2032 | } else { |
| | 2033 | $is_unchanged_incoming_value = ( |
| | 2034 | isset( $args['data'][ $prefixed_setting_id ] ) |
| | 2035 | && |
| | 2036 | array_key_exists( 'value', $args['data'][ $prefixed_setting_id ] ) |
| | 2037 | && |
| | 2038 | $args['data'][ $prefixed_setting_id ]['value'] === $setting_value |
| | 2039 | ); |
| | 2040 | if ( $is_unchanged_incoming_value ) { |
| | 2041 | $unchanged_incoming_setting_ids[] = $setting_id; |
| | 2042 | } |
| 2031 | 2043 | } |
| 2032 | 2044 | } |
| 2033 | 2045 | $post_values = wp_array_slice_assoc( $post_values, $changed_setting_ids ); |
| … |
… |
final class WP_Customize_Manager { |
| 2064 | 2076 | return new WP_Error( 'transaction_fail', '', $response ); |
| 2065 | 2077 | } |
| 2066 | 2078 | |
| | 2079 | // Ensure that any unchanged settings that were passed in among the data are marked as valid. |
| | 2080 | $setting_validities = array_merge( |
| | 2081 | array_fill_keys( $unchanged_incoming_setting_ids, true ), |
| | 2082 | $setting_validities |
| | 2083 | ); |
| | 2084 | |
| 2067 | 2085 | $response = array( |
| 2068 | 2086 | 'setting_validities' => $setting_validities, |
| 2069 | 2087 | ); |