Completed
Push — develop ( 4b580b...a19604 )
by Aristeides
02:58
created
modules/postmessage/class-kirki-modules-postmessage.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -113,10 +113,10 @@  discard block
 block discarded – undo
113 113
 			$js_var['index_key'] = $key;
114 114
 			$callback = $this->get_callback( $args );
115 115
 			if ( is_callable( $callback ) ) {
116
-				$field['scripts'][ $key ] = call_user_func_array( $callback, array( $js_var, $args ) );
116
+				$field['scripts'][$key] = call_user_func_array( $callback, array( $js_var, $args ) );
117 117
 				continue;
118 118
 			}
119
-			$field['scripts'][ $key ] = $this->script_var( $js_var );
119
+			$field['scripts'][$key] = $this->script_var( $js_var );
120 120
 		}
121 121
 		$combo_extra_script = '';
122 122
 		$combo_css_script   = '';
@@ -207,7 +207,7 @@  discard block
 block discarded – undo
207 207
 		$property_script = '';
208 208
 
209 209
 		// Define choice.
210
-		$choice  = ( isset( $args['choice'] ) && '' !== $args['choice'] ) ? $args['choice'] : '';
210
+		$choice = ( isset( $args['choice'] ) && '' !== $args['choice'] ) ? $args['choice'] : '';
211 211
 
212 212
 		$value_key = 'newval' . $args['index_key'];
213 213
 		$property_script .= $value_key . '=newval;';
@@ -297,7 +297,7 @@  discard block
 block discarded – undo
297 297
 			'font-weight'    => 'fontWeight',
298 298
 			'font-style'     => 'fontStyle',
299 299
 		);
300
-		$choice_condition = ( isset( $args['choice'] ) && '' !== $args['choice'] && isset( $css_build_array[ $args['choice'] ] ) );
300
+		$choice_condition = ( isset( $args['choice'] ) && '' !== $args['choice'] && isset( $css_build_array[$args['choice']] ) );
301 301
 		$script .= ( ! $choice_condition ) ? $webfont_loader : '';
302 302
 		foreach ( $css_build_array as $property => $var ) {
303 303
 			if ( $choice_condition && $property !== $args['choice'] ) {
@@ -378,7 +378,7 @@  discard block
 block discarded – undo
378 378
 			'units'         => '',
379 379
 			'js_callback'   => array( '', '' ),
380 380
 			'value_pattern' => '',
381
-		));
381
+		) );
382 382
 
383 383
 		// Element should be a string.
384 384
 		if ( is_array( $args['element'] ) ) {
Please login to merge, or discard this patch.