@@ -35,7 +35,7 @@ |
||
35 | 35 | $property = $output['property'] . '-' . $key; |
36 | 36 | } |
37 | 37 | $output['media_query'] = ( isset( $output['media_query'] ) ) ? $output['media_query'] : 'global'; |
38 | - $this->styles[ $output['media_query'] ][ $output['element'] ][ $property ] = $sub_value; |
|
38 | + $this->styles[$output['media_query']][$output['element']][$property] = $sub_value; |
|
39 | 39 | |
40 | 40 | } |
41 | 41 | } |
@@ -38,14 +38,14 @@ |
||
38 | 38 | // Add backup font. |
39 | 39 | if ( Kirki_Fonts::is_google_font( $this->value ) ) { |
40 | 40 | |
41 | - if ( isset( $google_fonts_array[ $this->value ] ) && isset( $google_fonts_array[ $this->value ]['category'] ) ) { |
|
42 | - if ( isset( $backup_fonts[ $google_fonts_array[ $this->value ]['category'] ] ) ) { |
|
41 | + if ( isset( $google_fonts_array[$this->value] ) && isset( $google_fonts_array[$this->value]['category'] ) ) { |
|
42 | + if ( isset( $backup_fonts[$google_fonts_array[$this->value]['category']] ) ) { |
|
43 | 43 | |
44 | 44 | // Add double quotes if needed. |
45 | 45 | if ( false !== strpos( $this->value, ' ' ) && false === strpos( $this->value, '"' ) ) { |
46 | - $this->value = '"' . $this->value . '", ' . $backup_fonts[ $google_fonts_array[ $this->value ]['category'] ]; |
|
46 | + $this->value = '"' . $this->value . '", ' . $backup_fonts[$google_fonts_array[$this->value]['category']]; |
|
47 | 47 | } else { |
48 | - $this->value .= ', ' . $backup_fonts[ $google_fonts_array[ $this->value ]['category'] ]; |
|
48 | + $this->value .= ', ' . $backup_fonts[$google_fonts_array[$this->value]['category']]; |
|
49 | 49 | } |
50 | 50 | } |
51 | 51 | } |
@@ -105,14 +105,14 @@ discard block |
||
105 | 105 | $available_variants = array(); |
106 | 106 | foreach ( $variants as $variant ) { |
107 | 107 | if ( array_key_exists( $variant, $all_variants ) ) { |
108 | - $available_variants[] = array( 'id' => $variant, 'label' => $all_variants[ $variant ] ); |
|
108 | + $available_variants[] = array( 'id' => $variant, 'label' => $all_variants[$variant] ); |
|
109 | 109 | } |
110 | 110 | } |
111 | 111 | |
112 | 112 | $available_subsets = array(); |
113 | 113 | foreach ( $subsets as $subset ) { |
114 | 114 | if ( array_key_exists( $subset, $all_subsets ) ) { |
115 | - $available_subsets[] = array( 'id' => $subset, 'label' => $all_subsets[ $subset ] ); |
|
115 | + $available_subsets[] = array( 'id' => $subset, 'label' => $all_subsets[$subset] ); |
|
116 | 116 | } |
117 | 117 | } |
118 | 118 | |
@@ -388,7 +388,7 @@ discard block |
||
388 | 388 | if ( false === $id ) { |
389 | 389 | return $translation_strings; |
390 | 390 | } |
391 | - return $translation_strings[ $id ]; |
|
391 | + return $translation_strings[$id]; |
|
392 | 392 | } |
393 | 393 | |
394 | 394 | /** |
@@ -52,7 +52,7 @@ |
||
52 | 52 | |
53 | 53 | // Sanitize each sub-value separately. |
54 | 54 | foreach ( $value as $key => $sub_value ) { |
55 | - $value[ $key ] = Kirki_Sanitize_Values::css_dimension( $sub_value ); |
|
55 | + $value[$key] = Kirki_Sanitize_Values::css_dimension( $sub_value ); |
|
56 | 56 | } |
57 | 57 | return $value; |
58 | 58 |
@@ -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 | |
56 | 56 | // Add the section. |
@@ -49,7 +49,7 @@ |
||
49 | 49 | if ( ! isset( $args['type'] ) || ! array_key_exists( $args['type'], $this->panel_types ) ) { |
50 | 50 | $args['type'] = 'default'; |
51 | 51 | } |
52 | - $panel_classname = $this->panel_types[ $args['type'] ]; |
|
52 | + $panel_classname = $this->panel_types[$args['type']]; |
|
53 | 53 | |
54 | 54 | $wp_customize->add_panel( new $panel_classname( $wp_customize, sanitize_key( $args['id'] ), $args ) ); |
55 | 55 |
@@ -70,9 +70,9 @@ |
||
70 | 70 | // Make sure that every row is an array, not an object. |
71 | 71 | foreach ( $sanitized as $key => $_value ) { |
72 | 72 | if ( empty( $_value ) ) { |
73 | - unset( $sanitized[ $key ] ); |
|
73 | + unset( $sanitized[$key] ); |
|
74 | 74 | } else { |
75 | - $sanitized[ $key ] = (array) $_value; |
|
75 | + $sanitized[$key] = (array) $_value; |
|
76 | 76 | } |
77 | 77 | } |
78 | 78 |
@@ -52,7 +52,7 @@ |
||
52 | 52 | } |
53 | 53 | $sanitized_value = array(); |
54 | 54 | foreach ( $value as $sub_value ) { |
55 | - if ( isset( $this->choices[ $sub_value ] ) ) { |
|
55 | + if ( isset( $this->choices[$sub_value] ) ) { |
|
56 | 56 | $sanitized_value[] = esc_attr( $sub_value ); |
57 | 57 | } |
58 | 58 | } |
@@ -76,7 +76,7 @@ |
||
76 | 76 | if ( is_array( $value ) ) { |
77 | 77 | foreach ( $value as $key => $subvalue ) { |
78 | 78 | if ( '' !== $subvalue || isset( $this->choices[''] ) ) { |
79 | - $value[ $key ] = esc_attr( $subvalue ); |
|
79 | + $value[$key] = esc_attr( $subvalue ); |
|
80 | 80 | } |
81 | 81 | } |
82 | 82 | return $value; |