Passed
Push — develop ( 0a470d...6aafd6 )
by Aristeides
04:22
created
core/class-kirki-init.php 1 patch
Spacing   +12 added lines, -12 removed lines patch added patch discarded remove patch
@@ -62,8 +62,8 @@  discard block
 block discarded – undo
62 62
 
63 63
 		// Apply the kirki_config filter.
64 64
 		$config = apply_filters( 'kirki_config', array() );
65
-		if ( isset( $config['url_path'] ) ) {
66
-			Kirki::$url = $config['url_path'];
65
+		if ( isset( $config[ 'url_path' ] ) ) {
66
+			Kirki::$url = $config[ 'url_path' ];
67 67
 		}
68 68
 
69 69
 		// Make sure the right protocol is used.
@@ -143,7 +143,7 @@  discard block
 block discarded – undo
143 143
 
144 144
 		$this->control_types = $this->default_control_types();
145 145
 		if ( ! class_exists( 'WP_Customize_Code_Editor_Control' ) ) {
146
-			unset( $this->control_types['code_editor'] );
146
+			unset( $this->control_types[ 'code_editor' ] );
147 147
 		}
148 148
 		foreach ( $this->control_types as $key => $classname ) {
149 149
 			if ( ! class_exists( $classname ) ) {
@@ -174,10 +174,10 @@  discard block
 block discarded – undo
174 174
 		if ( ! empty( Kirki::$panels ) ) {
175 175
 			foreach ( Kirki::$panels as $panel_args ) {
176 176
 				// Extra checks for nested panels.
177
-				if ( isset( $panel_args['panel'] ) ) {
178
-					if ( isset( Kirki::$panels[ $panel_args['panel'] ] ) ) {
177
+				if ( isset( $panel_args[ 'panel' ] ) ) {
178
+					if ( isset( Kirki::$panels[ $panel_args[ 'panel' ] ] ) ) {
179 179
 						// Set the type to nested.
180
-						$panel_args['type'] = 'kirki-nested';
180
+						$panel_args[ 'type' ] = 'kirki-nested';
181 181
 					}
182 182
 				}
183 183
 
@@ -195,14 +195,14 @@  discard block
 block discarded – undo
195 195
 		if ( ! empty( Kirki::$sections ) ) {
196 196
 			foreach ( Kirki::$sections as $section_args ) {
197 197
 				// Extra checks for nested sections.
198
-				if ( isset( $section_args['section'] ) ) {
199
-					if ( isset( Kirki::$sections[ $section_args['section'] ] ) ) {
198
+				if ( isset( $section_args[ 'section' ] ) ) {
199
+					if ( isset( Kirki::$sections[ $section_args[ 'section' ] ] ) ) {
200 200
 						// Set the type to nested.
201
-						$section_args['type'] = 'kirki-nested';
201
+						$section_args[ 'type' ] = 'kirki-nested';
202 202
 						// We need to check if the parent section is nested inside a panel.
203
-						$parent_section = Kirki::$sections[ $section_args['section'] ];
204
-						if ( isset( $parent_section['panel'] ) ) {
205
-							$section_args['panel'] = $parent_section['panel'];
203
+						$parent_section = Kirki::$sections[ $section_args[ 'section' ] ];
204
+						if ( isset( $parent_section[ 'panel' ] ) ) {
205
+							$section_args[ 'panel' ] = $parent_section[ 'panel' ];
206 206
 						}
207 207
 					}
208 208
 				}
Please login to merge, or discard this patch.