@@ -257,13 +257,13 @@ discard block  | 
                                                    ||
| 257 | 257 | |
| 258 | 258 | // Get the config arguments, and merge them with the defaults.  | 
                                                        
| 259 | 259 | $config_defaults = ( isset( Kirki::$config['global'] ) ) ? Kirki::$config['global'] : array();  | 
                                                        
| 260 | -		if ( 'global' !== $this->kirki_config && isset( Kirki::$config[ $this->kirki_config ] ) ) { | 
                                                        |
| 261 | - $config_defaults = Kirki::$config[ $this->kirki_config ];  | 
                                                        |
| 260 | +		if ( 'global' !== $this->kirki_config && isset( Kirki::$config[$this->kirki_config] ) ) { | 
                                                        |
| 261 | + $config_defaults = Kirki::$config[$this->kirki_config];  | 
                                                        |
| 262 | 262 | }  | 
                                                        
| 263 | 263 | $config_defaults = ( is_array( $config_defaults ) ) ? $config_defaults : array();  | 
                                                        
| 264 | 264 |  		foreach ( $config_defaults as $key => $value ) { | 
                                                        
| 265 | -			if ( isset( $defaults[ $key ] ) && ! empty( $value ) && $value !== $defaults[ $key ] ) { | 
                                                        |
| 266 | - $defaults[ $key ] = $value;  | 
                                                        |
| 265 | +			if ( isset( $defaults[$key] ) && ! empty( $value ) && $value !== $defaults[$key] ) { | 
                                                        |
| 266 | + $defaults[$key] = $value;  | 
                                                        |
| 267 | 267 | }  | 
                                                        
| 268 | 268 | }  | 
                                                        
| 269 | 269 | |
@@ -308,11 +308,11 @@ discard block  | 
                                                    ||
| 308 | 308 | // Get all arguments with their values.  | 
                                                        
| 309 | 309 | $args = get_object_vars( $this );  | 
                                                        
| 310 | 310 |  		foreach ( array_keys( $args ) as $key ) { | 
                                                        
| 311 | - $args[ $key ] = $this->$key;  | 
                                                        |
| 311 | + $args[$key] = $this->$key;  | 
                                                        |
| 312 | 312 | }  | 
                                                        
| 313 | 313 | |
| 314 | 314 | // Add the field to the static $fields variable properly indexed.  | 
                                                        
| 315 | - Kirki::$fields[ $this->settings ] = $args;  | 
                                                        |
| 315 | + Kirki::$fields[$this->settings] = $args;  | 
                                                        |
| 316 | 316 | |
| 317 | 317 | }  | 
                                                        
| 318 | 318 | |
@@ -407,7 +407,7 @@ discard block  | 
                                                    ||
| 407 | 407 |  			if ( ! is_array( $args ) || ! isset( $args['selector'] ) || ! isset( $args['render_callback'] ) || ! is_callable( $args['render_callback'] ) ) { | 
                                                        
| 408 | 408 | /* translators: %1$s represents the field ID where the error occurs. */  | 
                                                        
| 409 | 409 | _doing_it_wrong( __METHOD__, sprintf( esc_attr__( '"partial_refresh" invalid entry in field %s', 'kirki' ), esc_attr( $this->settings ) ), '3.0.10' );  | 
                                                        
| 410 | - unset( $this->partial_refresh[ $id ] );  | 
                                                        |
| 410 | + unset( $this->partial_refresh[$id] );  | 
                                                        |
| 411 | 411 | continue;  | 
                                                        
| 412 | 412 | }  | 
                                                        
| 413 | 413 | }  | 
                                                        
@@ -435,10 +435,10 @@ discard block  | 
                                                    ||
| 435 | 435 | }  | 
                                                        
| 436 | 436 | $settings = array();  | 
                                                        
| 437 | 437 |  		foreach ( $this->settings as $setting_key => $setting_value ) { | 
                                                        
| 438 | - $settings[ $setting_key ] = $setting_value;  | 
                                                        |
| 438 | + $settings[$setting_key] = $setting_value;  | 
                                                        |
| 439 | 439 | // If we're using serialized options then we need to spice this up.  | 
                                                        
| 440 | 440 |  			if ( 'option' === $this->option_type && '' !== $this->option_name && ( false === strpos( $setting_key, '[' ) ) ) { | 
                                                        
| 441 | -				$settings[ $setting_key ] = "{$this->option_name}[{$setting_value}]"; | 
                                                        |
| 441 | +				$settings[$setting_key] = "{$this->option_name}[{$setting_value}]"; | 
                                                        |
| 442 | 442 | }  | 
                                                        
| 443 | 443 | }  | 
                                                        
| 444 | 444 | $this->settings = $settings;  | 
                                                        
@@ -550,27 +550,27 @@ discard block  | 
                                                    ||
| 550 | 550 | }  | 
                                                        
| 551 | 551 |  		foreach ( $this->output as $key => $output ) { | 
                                                        
| 552 | 552 |  			if ( empty( $output ) || ! isset( $output['element'] ) ) { | 
                                                        
| 553 | - unset( $this->output[ $key ] );  | 
                                                        |
| 553 | + unset( $this->output[$key] );  | 
                                                        |
| 554 | 554 | continue;  | 
                                                        
| 555 | 555 | }  | 
                                                        
| 556 | 556 |  			if ( ! isset( $output['sanitize_callback'] ) && isset( $output['callback'] ) ) { | 
                                                        
| 557 | - $this->output[ $key ]['sanitize_callback'] = $output['callback'];  | 
                                                        |
| 557 | + $this->output[$key]['sanitize_callback'] = $output['callback'];  | 
                                                        |
| 558 | 558 | }  | 
                                                        
| 559 | 559 | // Convert element arrays to strings.  | 
                                                        
| 560 | 560 |  			if ( isset( $output['element'] ) && is_array( $output['element'] ) ) { | 
                                                        
| 561 | - $this->output[ $key ]['element'] = array_unique( $this->output[ $key ]['element'] );  | 
                                                        |
| 562 | - sort( $this->output[ $key ]['element'] );  | 
                                                        |
| 561 | + $this->output[$key]['element'] = array_unique( $this->output[$key]['element'] );  | 
                                                        |
| 562 | + sort( $this->output[$key]['element'] );  | 
                                                        |
| 563 | 563 | |
| 564 | 564 | // Trim each element in the array.  | 
                                                        
| 565 | -				foreach ( $this->output[ $key ]['element'] as $index => $element ) { | 
                                                        |
| 566 | - $this->output[ $key ]['element'][ $index ] = trim( $element );  | 
                                                        |
| 565 | +				foreach ( $this->output[$key]['element'] as $index => $element ) { | 
                                                        |
| 566 | + $this->output[$key]['element'][$index] = trim( $element );  | 
                                                        |
| 567 | 567 | }  | 
                                                        
| 568 | - $this->output[ $key ]['element'] = implode( ',', $this->output[ $key ]['element'] );  | 
                                                        |
| 568 | + $this->output[$key]['element'] = implode( ',', $this->output[$key]['element'] );  | 
                                                        |
| 569 | 569 | }  | 
                                                        
| 570 | 570 | |
| 571 | 571 | // Fix for https://github.com/aristath/kirki/issues/1659#issuecomment-346229751.  | 
                                                        
| 572 | - $this->output[ $key ]['element'] = str_replace( array( "\t", "\n", "\r", "\0", "\x0B" ), ' ', $this->output[ $key ]['element'] );  | 
                                                        |
| 573 | - $this->output[ $key ]['element'] = trim( preg_replace( '/\s+/', ' ', $this->output[ $key ]['element'] ) );  | 
                                                        |
| 572 | + $this->output[$key]['element'] = str_replace( array( "\t", "\n", "\r", "\0", "\x0B" ), ' ', $this->output[$key]['element'] );  | 
                                                        |
| 573 | + $this->output[$key]['element'] = trim( preg_replace( '/\s+/', ' ', $this->output[$key]['element'] ) );  | 
                                                        |
| 574 | 574 | }  | 
                                                        
| 575 | 575 | }  | 
                                                        
| 576 | 576 | |
@@ -47,12 +47,12 @@ discard block  | 
                                                    ||
| 47 | 47 |  		foreach ( $properties as $property ) { | 
                                                        
| 48 | 48 | |
| 49 | 49 | // Early exit if the value is not in the defaults.  | 
                                                        
| 50 | -			if ( ! isset( $this->field['default'][ $property ] ) ) { | 
                                                        |
| 50 | +			if ( ! isset( $this->field['default'][$property] ) ) { | 
                                                        |
| 51 | 51 | continue;  | 
                                                        
| 52 | 52 | }  | 
                                                        
| 53 | 53 | |
| 54 | 54 | // Early exit if the value is not saved in the values.  | 
                                                        
| 55 | -			if ( ! isset( $value[ $property ] ) || ! $value[ $property ] ) { | 
                                                        |
| 55 | +			if ( ! isset( $value[$property] ) || ! $value[$property] ) { | 
                                                        |
| 56 | 56 | continue;  | 
                                                        
| 57 | 57 | }  | 
                                                        
| 58 | 58 | |
@@ -61,7 +61,7 @@ discard block  | 
                                                    ||
| 61 | 61 | continue;  | 
                                                        
| 62 | 62 | }  | 
                                                        
| 63 | 63 | |
| 64 | - $property_value = $this->process_property_value( $property, $value[ $property ] );  | 
                                                        |
| 64 | + $property_value = $this->process_property_value( $property, $value[$property] );  | 
                                                        |
| 65 | 65 |  			if ( 'font-family' === $property ) { | 
                                                        
| 66 | 66 | $value['font-backup'] = ( isset( $value['font-backup'] ) ) ? $value['font-backup'] : '';  | 
                                                        
| 67 | 67 | $property_value = $this->process_property_value( $property, array(  | 
                                                        
@@ -71,7 +71,7 @@ discard block  | 
                                                    ||
| 71 | 71 | }  | 
                                                        
| 72 | 72 | $property = ( isset( $output['choice'] ) && isset( $output['property'] ) ) ? $output['property'] : $property;  | 
                                                        
| 73 | 73 | $property_value = ( is_array( $property_value ) && isset( $property_value[0] ) ) ? $property_value[0] : $property_value;  | 
                                                        
| 74 | - $this->styles[ $output['media_query'] ][ $output['element'] ][ $property ] = $output['prefix'] . $property_value . $output['suffix'];  | 
                                                        |
| 74 | + $this->styles[$output['media_query']][$output['element']][$property] = $output['prefix'] . $property_value . $output['suffix'];  | 
                                                        |
| 75 | 75 | }  | 
                                                        
| 76 | 76 | }  | 
                                                        
| 77 | 77 | }  | 
                                                        
@@ -172,7 +172,7 @@ discard block  | 
                                                    ||
| 172 | 172 | 'kirki-multicolor' => 'Kirki_Output_Field_Multicolor',  | 
                                                        
| 173 | 173 | ) );  | 
                                                        
| 174 | 174 |  		if ( array_key_exists( self::$field_type, $field_output_classes ) ) { | 
                                                        
| 175 | - $classname = $field_output_classes[ self::$field_type ];  | 
                                                        |
| 175 | + $classname = $field_output_classes[self::$field_type];  | 
                                                        |
| 176 | 176 | }  | 
                                                        
| 177 | 177 | $obj = new $classname( $field['kirki_config'], self::$output, self::$value, $field );  | 
                                                        
| 178 | 178 | return $obj->get_styles();  | 
                                                        
@@ -247,10 +247,10 @@ discard block  | 
                                                    ||
| 247 | 247 | 'transition',  | 
                                                        
| 248 | 248 | 'transition-property',  | 
                                                        
| 249 | 249 |  						), true ) ) { | 
                                                        
| 250 | - unset( $css[ $media_query ][ $element ][ $property ] );  | 
                                                        |
| 251 | - $css[ $media_query ][ $element ][ '-webkit-' . $property ] = $value;  | 
                                                        |
| 252 | - $css[ $media_query ][ $element ][ '-moz-' . $property ] = $value;  | 
                                                        |
| 253 | - $css[ $media_query ][ $element ][ $property ] = $value;  | 
                                                        |
| 250 | + unset( $css[$media_query][$element][$property] );  | 
                                                        |
| 251 | + $css[$media_query][$element]['-webkit-' . $property] = $value;  | 
                                                        |
| 252 | + $css[$media_query][$element]['-moz-' . $property] = $value;  | 
                                                        |
| 253 | + $css[$media_query][$element][$property] = $value;  | 
                                                        |
| 254 | 254 | }  | 
                                                        
| 255 | 255 | |
| 256 | 256 | // Add -ms-* and -o-*.  | 
                                                        
@@ -260,10 +260,10 @@ discard block  | 
                                                    ||
| 260 | 260 | 'transition',  | 
                                                        
| 261 | 261 | 'transition-property',  | 
                                                        
| 262 | 262 |  						), true ) ) { | 
                                                        
| 263 | - unset( $css[ $media_query ][ $element ][ $property ] );  | 
                                                        |
| 264 | - $css[ $media_query ][ $element ][ '-ms-' . $property ] = $value;  | 
                                                        |
| 265 | - $css[ $media_query ][ $element ][ '-o-' . $property ] = $value;  | 
                                                        |
| 266 | - $css[ $media_query ][ $element ][ $property ] = $value;  | 
                                                        |
| 263 | + unset( $css[$media_query][$element][$property] );  | 
                                                        |
| 264 | + $css[$media_query][$element]['-ms-' . $property] = $value;  | 
                                                        |
| 265 | + $css[$media_query][$element]['-o-' . $property] = $value;  | 
                                                        |
| 266 | + $css[$media_query][$element][$property] = $value;  | 
                                                        |
| 267 | 267 | }  | 
                                                        
| 268 | 268 | }  | 
                                                        
| 269 | 269 | }  | 
                                                        
@@ -56,16 +56,16 @@ discard block  | 
                                                    ||
| 56 | 56 | |
| 57 | 57 |  		if ( is_array( $this->json['value'] ) ) { | 
                                                        
| 58 | 58 |  			foreach ( array_keys( $this->json['value'] ) as $key ) { | 
                                                        
| 59 | -				if ( ! in_array( $key, array( 'variant', 'font-weight', 'font-style' ), true ) && ! isset( $this->json['default'][ $key ] ) ) { | 
                                                        |
| 60 | - unset( $this->json['value'][ $key ] );  | 
                                                        |
| 59 | +				if ( ! in_array( $key, array( 'variant', 'font-weight', 'font-style' ), true ) && ! isset( $this->json['default'][$key] ) ) { | 
                                                        |
| 60 | + unset( $this->json['value'][$key] );  | 
                                                        |
| 61 | 61 | }  | 
                                                        
| 62 | 62 | // Fix for https://wordpress.org/support/topic/white-font-after-updateing-to-3-0-16.  | 
                                                        
| 63 | -				if ( ! isset( $this->json['default'][ $key ] ) ) { | 
                                                        |
| 64 | - unset( $this->json['value'][ $key ] );  | 
                                                        |
| 63 | +				if ( ! isset( $this->json['default'][$key] ) ) { | 
                                                        |
| 64 | + unset( $this->json['value'][$key] );  | 
                                                        |
| 65 | 65 | }  | 
                                                        
| 66 | 66 | // Fix for https://github.com/aristath/kirki/issues/1405.  | 
                                                        
| 67 | -				if ( isset( $this->json['default'][ $key ] ) && false === $this->json['default'][ $key ] ) { | 
                                                        |
| 68 | - unset( $this->json['value'][ $key ] );  | 
                                                        |
| 67 | +				if ( isset( $this->json['default'][$key] ) && false === $this->json['default'][$key] ) { | 
                                                        |
| 68 | + unset( $this->json['value'][$key] );  | 
                                                        |
| 69 | 69 | }  | 
                                                        
| 70 | 70 | }  | 
                                                        
| 71 | 71 | }  | 
                                                        
@@ -281,7 +281,7 @@ discard block  | 
                                                    ||
| 281 | 281 |  			if ( is_string( $variant ) ) { | 
                                                        
| 282 | 282 | $final_variants[] = array(  | 
                                                        
| 283 | 283 | 'id' => $variant,  | 
                                                        
| 284 | - 'label' => isset( $all_variants[ $variant ] ) ? $all_variants[ $variant ] : $variant,  | 
                                                        |
| 284 | + 'label' => isset( $all_variants[$variant] ) ? $all_variants[$variant] : $variant,  | 
                                                        |
| 285 | 285 | );  | 
                                                        
| 286 | 286 |  			} elseif ( is_array( $variant ) && isset( $variant['id'] ) && isset( $variant['label'] ) ) { | 
                                                        
| 287 | 287 | $final_variants[] = $variant;  | 
                                                        
@@ -364,7 +364,7 @@ discard block  | 
                                                    ||
| 364 | 364 |  					if ( array_key_exists( $variant, $all_variants ) ) { | 
                                                        
| 365 | 365 | $available_variants[] = array(  | 
                                                        
| 366 | 366 | 'id' => $variant,  | 
                                                        
| 367 | - 'label' => $all_variants[ $variant ],  | 
                                                        |
| 367 | + 'label' => $all_variants[$variant],  | 
                                                        |
| 368 | 368 | );  | 
                                                        
| 369 | 369 | }  | 
                                                        
| 370 | 370 | }  | 
                                                        
@@ -376,7 +376,7 @@ discard block  | 
                                                    ||
| 376 | 376 |  					if ( array_key_exists( $subset, $all_subsets ) ) { | 
                                                        
| 377 | 377 | $available_subsets[] = array(  | 
                                                        
| 378 | 378 | 'id' => $subset,  | 
                                                        
| 379 | - 'label' => $all_subsets[ $subset ],  | 
                                                        |
| 379 | + 'label' => $all_subsets[$subset],  | 
                                                        |
| 380 | 380 | );  | 
                                                        
| 381 | 381 | }  | 
                                                        
| 382 | 382 | }  | 
                                                        
@@ -114,7 +114,7 @@ discard block  | 
                                                    ||
| 114 | 114 | |
| 115 | 115 | $config = Kirki_Config::get_instance( $config_id, $args );  | 
                                                        
| 116 | 116 | $config_args = $config->get_config();  | 
                                                        
| 117 | - self::$config[ $config_args['id'] ] = $config_args;  | 
                                                        |
| 117 | + self::$config[$config_args['id']] = $config_args;  | 
                                                        |
| 118 | 118 | }  | 
                                                        
| 119 | 119 | |
| 120 | 120 | /**  | 
                                                        
@@ -133,7 +133,7 @@ discard block  | 
                                                    ||
| 133 | 133 | $args['type'] = ( isset( $args['type'] ) ) ? $args['type'] : 'default';  | 
                                                        
| 134 | 134 | $args['type'] = 'kirki-' . $args['type'];  | 
                                                        
| 135 | 135 | |
| 136 | - self::$panels[ $args['id'] ] = $args;  | 
                                                        |
| 136 | + self::$panels[$args['id']] = $args;  | 
                                                        |
| 137 | 137 | }  | 
                                                        
| 138 | 138 | |
| 139 | 139 | /**  | 
                                                        
@@ -153,7 +153,7 @@ discard block  | 
                                                    ||
| 153 | 153 | $args['type'] = ( isset( $args['type'] ) ) ? $args['type'] : 'default';  | 
                                                        
| 154 | 154 | $args['type'] = 'kirki-' . $args['type'];  | 
                                                        
| 155 | 155 | |
| 156 | - self::$sections[ $args['id'] ] = $args;  | 
                                                        |
| 156 | + self::$sections[$args['id']] = $args;  | 
                                                        |
| 157 | 157 | }  | 
                                                        
| 158 | 158 | |
| 159 | 159 | /**  | 
                                                        
@@ -205,9 +205,9 @@ discard block  | 
                                                    ||
| 205 | 205 | */  | 
                                                        
| 206 | 206 |  	public static function get_config_param( $id, $param ) { | 
                                                        
| 207 | 207 | |
| 208 | -		if ( ! isset( self::$config[ $id ] ) || ! isset( self::$config[ $id ][ $param ] ) ) { | 
                                                        |
| 208 | +		if ( ! isset( self::$config[$id] ) || ! isset( self::$config[$id][$param] ) ) { | 
                                                        |
| 209 | 209 | return '';  | 
                                                        
| 210 | 210 | }  | 
                                                        
| 211 | - return self::$config[ $id ][ $param ];  | 
                                                        |
| 211 | + return self::$config[$id][$param];  | 
                                                        |
| 212 | 212 | }  | 
                                                        
| 213 | 213 | }  | 
                                                        
@@ -103,16 +103,16 @@ discard block  | 
                                                    ||
| 103 | 103 | }  | 
                                                        
| 104 | 104 |  			if ( is_array( $value ) ) { | 
                                                        
| 105 | 105 |  				foreach ( array_keys( $value ) as $value_k ) { | 
                                                        
| 106 | -					if ( ! is_string( $value[ $value_k ] ) ) { | 
                                                        |
| 106 | +					if ( ! is_string( $value[$value_k] ) ) { | 
                                                        |
| 107 | 107 | continue;  | 
                                                        
| 108 | 108 | }  | 
                                                        
| 109 | 109 |  					if ( isset( $output['choice'] ) ) { | 
                                                        
| 110 | 110 |  						if ( $output['choice'] === $value_k ) { | 
                                                        
| 111 | - $value[ $output['choice'] ] = str_replace( '$', $value[ $output['choice'] ], $output['value_pattern'] );  | 
                                                        |
| 111 | + $value[$output['choice']] = str_replace( '$', $value[$output['choice']], $output['value_pattern'] );  | 
                                                        |
| 112 | 112 | }  | 
                                                        
| 113 | 113 | continue;  | 
                                                        
| 114 | 114 | }  | 
                                                        
| 115 | - $value[ $value_k ] = str_replace( '$', $value[ $value_k ], $output['value_pattern'] );  | 
                                                        |
| 115 | + $value[$value_k] = str_replace( '$', $value[$value_k], $output['value_pattern'] );  | 
                                                        |
| 116 | 116 | }  | 
                                                        
| 117 | 117 | }  | 
                                                        
| 118 | 118 | $value = $this->apply_pattern_replace( $output, $value );  | 
                                                        
@@ -142,16 +142,16 @@ discard block  | 
                                                    ||
| 142 | 142 |  						if ( is_array( $options ) ) { | 
                                                        
| 143 | 143 |  							if ( $option_name ) { | 
                                                        
| 144 | 144 | $subkey = str_replace( array( $option_name, '[', ']' ), '', $replace );  | 
                                                        
| 145 | - $replacement = ( isset( $options[ $subkey ] ) ) ? $options[ $subkey ] : '';  | 
                                                        |
| 145 | + $replacement = ( isset( $options[$subkey] ) ) ? $options[$subkey] : '';  | 
                                                        |
| 146 | 146 | break;  | 
                                                        
| 147 | 147 | }  | 
                                                        
| 148 | - $replacement = ( isset( $options[ $replace ] ) ) ? $options[ $replace ] : '';  | 
                                                        |
| 148 | + $replacement = ( isset( $options[$replace] ) ) ? $options[$replace] : '';  | 
                                                        |
| 149 | 149 | break;  | 
                                                        
| 150 | 150 | }  | 
                                                        
| 151 | 151 | $replacement = get_option( $replace );  | 
                                                        
| 152 | 152 | break;  | 
                                                        
| 153 | 153 | case 'site_option':  | 
                                                        
| 154 | - $replacement = ( is_array( $options ) && isset( $options[ $replace ] ) ) ? $options[ $replace ] : get_site_option( $replace );  | 
                                                        |
| 154 | + $replacement = ( is_array( $options ) && isset( $options[$replace] ) ) ? $options[$replace] : get_site_option( $replace );  | 
                                                        |
| 155 | 155 | break;  | 
                                                        
| 156 | 156 | case 'user_meta':  | 
                                                        
| 157 | 157 | $user_id = get_current_user_id();  | 
                                                        
@@ -166,8 +166,8 @@ discard block  | 
                                                    ||
| 166 | 166 | $replacement = ( false === $replacement ) ? '' : $replacement;  | 
                                                        
| 167 | 167 |  				if ( is_array( $value ) ) { | 
                                                        
| 168 | 168 |  					foreach ( $value as $k => $v ) { | 
                                                        
| 169 | - $_val = ( isset( $value[ $v ] ) ) ? $value[ $v ] : $v;  | 
                                                        |
| 170 | - $value[ $k ] = str_replace( $search, $replacement, $_val );  | 
                                                        |
| 169 | + $_val = ( isset( $value[$v] ) ) ? $value[$v] : $v;  | 
                                                        |
| 170 | + $value[$k] = str_replace( $search, $replacement, $_val );  | 
                                                        |
| 171 | 171 | }  | 
                                                        
| 172 | 172 | return $value;  | 
                                                        
| 173 | 173 | }  | 
                                                        
@@ -209,7 +209,7 @@ discard block  | 
                                                    ||
| 209 | 209 | }  | 
                                                        
| 210 | 210 | // If 'choice' is defined check for sub-values too.  | 
                                                        
| 211 | 211 | // Fixes https://github.com/aristath/kirki/issues/1416.  | 
                                                        
| 212 | -						if ( isset( $output['choice'] ) && isset( $value[ $output['choice'] ] ) && $exclude == $value[ $output['choice'] ] ) { | 
                                                        |
| 212 | +						if ( isset( $output['choice'] ) && isset( $value[$output['choice']] ) && $exclude == $value[$output['choice']] ) { | 
                                                        |
| 213 | 213 | $skip = true;  | 
                                                        
| 214 | 214 | }  | 
                                                        
| 215 | 215 | }  | 
                                                        
@@ -267,13 +267,13 @@ discard block  | 
                                                    ||
| 267 | 267 | 'background',  | 
                                                        
| 268 | 268 | );  | 
                                                        
| 269 | 269 |  		if ( in_array( $output['property'], $accepts_multiple, true ) ) { | 
                                                        
| 270 | -			if ( isset( $this->styles[ $output['media_query'] ][ $output['element'] ][ $output['property'] ] ) && ! is_array( $this->styles[ $output['media_query'] ][ $output['element'] ][ $output['property'] ] ) ) { | 
                                                        |
| 271 | - $this->styles[ $output['media_query'] ][ $output['element'] ][ $output['property'] ] = (array) $this->styles[ $output['media_query'] ][ $output['element'] ][ $output['property'] ];  | 
                                                        |
| 270 | +			if ( isset( $this->styles[$output['media_query']][$output['element']][$output['property']] ) && ! is_array( $this->styles[$output['media_query']][$output['element']][$output['property']] ) ) { | 
                                                        |
| 271 | + $this->styles[$output['media_query']][$output['element']][$output['property']] = (array) $this->styles[$output['media_query']][$output['element']][$output['property']];  | 
                                                        |
| 272 | 272 | }  | 
                                                        
| 273 | - $this->styles[ $output['media_query'] ][ $output['element'] ][ $output['property'] ][] = $output['prefix'] . $value . $output['units'] . $output['suffix'];  | 
                                                        |
| 273 | + $this->styles[$output['media_query']][$output['element']][$output['property']][] = $output['prefix'] . $value . $output['units'] . $output['suffix'];  | 
                                                        |
| 274 | 274 | return;  | 
                                                        
| 275 | 275 | }  | 
                                                        
| 276 | - $this->styles[ $output['media_query'] ][ $output['element'] ][ $output['property'] ] = $output['prefix'] . $this->process_property_value( $output['property'], $value ) . $output['units'] . $output['suffix'];  | 
                                                        |
| 276 | + $this->styles[$output['media_query']][$output['element']][$output['property']] = $output['prefix'] . $this->process_property_value( $output['property'], $value ) . $output['units'] . $output['suffix'];  | 
                                                        |
| 277 | 277 | }  | 
                                                        
| 278 | 278 | |
| 279 | 279 | /**  | 
                                                        
@@ -295,7 +295,7 @@ discard block  | 
                                                    ||
| 295 | 295 | )  | 
                                                        
| 296 | 296 | );  | 
                                                        
| 297 | 297 |  		if ( array_key_exists( $property, $properties ) ) { | 
                                                        
| 298 | - $classname = $properties[ $property ];  | 
                                                        |
| 298 | + $classname = $properties[$property];  | 
                                                        |
| 299 | 299 | $obj = new $classname( $property, $value );  | 
                                                        
| 300 | 300 | return $obj->get_value();  | 
                                                        
| 301 | 301 | }  | 
                                                        
@@ -141,10 +141,10 @@ discard block  | 
                                                    ||
| 141 | 141 | $js_var['index_key'] = $key;  | 
                                                        
| 142 | 142 | $callback = $this->get_callback( $args );  | 
                                                        
| 143 | 143 |  			if ( is_callable( $callback ) ) { | 
                                                        
| 144 | - $field['scripts'][ $key ] = call_user_func_array( $callback, array( $js_var, $args ) );  | 
                                                        |
| 144 | + $field['scripts'][$key] = call_user_func_array( $callback, array( $js_var, $args ) );  | 
                                                        |
| 145 | 145 | continue;  | 
                                                        
| 146 | 146 | }  | 
                                                        
| 147 | - $field['scripts'][ $key ] = $this->script_var( $js_var );  | 
                                                        |
| 147 | + $field['scripts'][$key] = $this->script_var( $js_var );  | 
                                                        |
| 148 | 148 | }  | 
                                                        
| 149 | 149 | $combo_extra_script = '';  | 
                                                        
| 150 | 150 | $combo_css_script = '';  | 
                                                        
@@ -338,7 +338,7 @@ discard block  | 
                                                    ||
| 338 | 338 | 'font-weight' => 'fontWeight',  | 
                                                        
| 339 | 339 | 'font-style' => 'fontStyle',  | 
                                                        
| 340 | 340 | );  | 
                                                        
| 341 | - $choice_condition = ( isset( $args['choice'] ) && '' !== $args['choice'] && isset( $css_build_array[ $args['choice'] ] ) );  | 
                                                        |
| 341 | + $choice_condition = ( isset( $args['choice'] ) && '' !== $args['choice'] && isset( $css_build_array[$args['choice']] ) );  | 
                                                        |
| 342 | 342 | $script .= ( ! $choice_condition ) ? $webfont_loader : '';  | 
                                                        
| 343 | 343 |  		foreach ( $css_build_array as $property => $var ) { | 
                                                        
| 344 | 344 |  			if ( $choice_condition && $property !== $args['choice'] ) { | 
                                                        
@@ -50,7 +50,7 @@  | 
                                                    ||
| 50 | 50 | $section_classname = 'WP_Customize_Section';  | 
                                                        
| 51 | 51 | |
| 52 | 52 |  		if ( isset( $args['type'] ) && array_key_exists( $args['type'], $this->section_types ) ) { | 
                                                        
| 53 | - $section_classname = $this->section_types[ $args['type'] ];  | 
                                                        |
| 53 | + $section_classname = $this->section_types[$args['type']];  | 
                                                        |
| 54 | 54 | }  | 
                                                        
| 55 | 55 |  		if ( isset( $args['type'] ) && 'kirki-outer' === $args['type'] ) { | 
                                                        
| 56 | 56 | $args['type'] = 'outer';  |