Passed
Push — develop ( ff75e1...e7463e )
by Remco
04:14
created
admin/tab-documentation.php 1 patch
Spacing   +15 added lines, -15 removed lines patch added patch discarded remove patch
@@ -628,47 +628,47 @@  discard block
 block discarded – undo
628 628
 
629 629
 		<?php foreach ( $providers as $provider ) : ?>
630 630
 
631
-			<?php if ( isset( $provider['resources'] ) && ! empty( $provider['resources'] ) ) : ?>
631
+			<?php if ( isset( $provider[ 'resources' ] ) && ! empty( $provider[ 'resources' ] ) ) : ?>
632 632
 
633 633
 				<tr class="alternate">
634 634
 					<td colspan="4">
635
-						<strong><?php echo esc_html( $provider['name'] ); ?></strong>
636
-						<small><a href="<?php echo esc_attr( $provider['url'] ); ?>"><?php echo esc_html( $provider['url'] ); ?></a></small>
635
+						<strong><?php echo esc_html( $provider[ 'name' ] ); ?></strong>
636
+						<small><a href="<?php echo esc_attr( $provider[ 'url' ] ); ?>"><?php echo esc_html( $provider[ 'url' ] ); ?></a></small>
637 637
 					</td>
638 638
 				</tr>
639 639
 
640
-				<?php foreach ( $provider['resources'] as $resource ) : ?>
640
+				<?php foreach ( $provider[ 'resources' ] as $resource ) : ?>
641 641
 
642 642
 					<?php
643 643
 
644 644
 					$href = null;
645 645
 
646
-					if ( isset( $resource['path'] ) ) {
647
-						$href = plugins_url( $resource['path'], Plugin::$file );
646
+					if ( isset( $resource[ 'path' ] ) ) {
647
+						$href = plugins_url( $resource[ 'path' ], Plugin::$file );
648 648
 					}
649 649
 
650
-					if ( isset( $resource['url'] ) ) {
651
-						$href = $resource['url'];
650
+					if ( isset( $resource[ 'url' ] ) ) {
651
+						$href = $resource[ 'url' ];
652 652
 					}
653 653
 
654 654
 					$classes = array();
655 655
 
656
-					if ( isset( $resource['deprecated'] ) ) {
657
-						$classes[] = 'deprecated';
656
+					if ( isset( $resource[ 'deprecated' ] ) ) {
657
+						$classes[ ] = 'deprecated';
658 658
 					}
659 659
 
660 660
 					?>
661 661
 					<tr class="<?php echo esc_attr( implode( ' ', $classes ) ); ?>">
662 662
 						<td>
663 663
 							<a href="<?php echo esc_attr( $href ); ?>">
664
-								<?php echo esc_html( $resource['name'] ); ?>
664
+								<?php echo esc_html( $resource[ 'name' ] ); ?>
665 665
 							</a>
666 666
 						</td>
667 667
 						<td>
668 668
 							<?php
669 669
 
670
-							if ( isset( $resource['date'] ) ) {
671
-								echo esc_html( $resource['date']->format( 'd-m-Y' ) );
670
+							if ( isset( $resource[ 'date' ] ) ) {
671
+								echo esc_html( $resource[ 'date' ]->format( 'd-m-Y' ) );
672 672
 							}
673 673
 
674 674
 							?>
@@ -676,8 +676,8 @@  discard block
 block discarded – undo
676 676
 						<td>
677 677
 							<?php
678 678
 
679
-							if ( isset( $resource['version'] ) ) {
680
-								echo esc_html( $resource['version'] );
679
+							if ( isset( $resource[ 'version' ] ) ) {
680
+								echo esc_html( $resource[ 'version' ] );
681 681
 							}
682 682
 
683 683
 							?>
Please login to merge, or discard this patch.
admin/meta-box-form-options.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -89,7 +89,7 @@
 block discarded – undo
89 89
 			}
90 90
 
91 91
 			// Add empty input field.
92
-			$choices[] = '';
92
+			$choices[ ] = '';
93 93
 
94 94
 			foreach ( $choices as $i => $amount ) {
95 95
 				if ( ! empty( $amount ) ) {
Please login to merge, or discard this patch.
admin/methods-wp-admin.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -28,23 +28,23 @@
 block discarded – undo
28 28
 				<td>
29 29
 					<?php
30 30
 
31
-					if ( isset( $method['icon'] ) ) {
32
-						printf( '<img src="%s" alt="" />', esc_attr( $method['icon'] ) );
31
+					if ( isset( $method[ 'icon' ] ) ) {
32
+						printf( '<img src="%s" alt="" />', esc_attr( $method[ 'icon' ] ) );
33 33
 					}
34 34
 
35 35
 					?>
36 36
 				</td>
37 37
 				<td>
38
-					<?php echo esc_html( $method['name'] ); ?>
38
+					<?php echo esc_html( $method[ 'name' ] ); ?>
39 39
 				</td>
40 40
 				<td>
41 41
 					<?php
42 42
 
43
-					if ( isset( $method['url'] ) ) {
43
+					if ( isset( $method[ 'url' ] ) ) {
44 44
 						printf(
45 45
 							'<a href="%s" target="_blank">%s</a>',
46
-							esc_attr( $method['url'] ),
47
-							esc_html( $method['url'] )
46
+							esc_attr( $method[ 'url' ] ),
47
+							esc_html( $method[ 'url' ] )
48 48
 						);
49 49
 					}
50 50
 
Please login to merge, or discard this patch.
admin/tab-system_status.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -245,8 +245,8 @@
 block discarded – undo
245 245
 					$version = curl_version();
246 246
 					// @codingStandardsIgnoreEnd
247 247
 
248
-					if ( isset( $version['version'] ) ) {
249
-						echo esc_html( $version['version'] );
248
+					if ( isset( $version[ 'version' ] ) ) {
249
+						echo esc_html( $version[ 'version' ] );
250 250
 					}
251 251
 				}
252 252
 
Please login to merge, or discard this patch.
admin/page-tools.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -30,7 +30,7 @@
 block discarded – undo
30 30
 			$classes = array( 'nav-tab' );
31 31
 
32 32
 			if ( $current_tab === $tab ) {
33
-				$classes[] = 'nav-tab-active';
33
+				$classes[ ] = 'nav-tab-active';
34 34
 			}
35 35
 
36 36
 			$url = add_query_arg(
Please login to merge, or discard this patch.
admin/page-about.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -60,7 +60,7 @@
 block discarded – undo
60 60
 			$classes = array( 'nav-tab' );
61 61
 
62 62
 			if ( $current_tab === $tab ) {
63
-				$classes[] = 'nav-tab-active';
63
+				$classes[ ] = 'nav-tab-active';
64 64
 			}
65 65
 
66 66
 			$url = add_query_arg( 'tab', $tab );
Please login to merge, or discard this patch.
admin/meta-box-gateway-test.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -28,7 +28,7 @@  discard block
 block discarded – undo
28 28
 
29 29
 	$inputs = array();
30 30
 
31
-	foreach ( $payment_methods['choices'][0]['options'] as $payment_method => $method_name ) {
31
+	foreach ( $payment_methods[ 'choices' ][ 0 ][ 'options' ] as $payment_method => $method_name ) {
32 32
 		$gateway->set_payment_method( $payment_method );
33 33
 
34 34
 		// Payment method input HTML.
@@ -43,7 +43,7 @@  discard block
 block discarded – undo
43 43
 	}
44 44
 
45 45
 	if ( $gateway->has_error() ) {
46
-		$pronamic_ideal_errors[] = $gateway->get_error();
46
+		$pronamic_ideal_errors[ ] = $gateway->get_error();
47 47
 	}
48 48
 
49 49
 	include Plugin::$dirname . '/views/errors.php';
@@ -60,7 +60,7 @@  discard block
 block discarded – undo
60 60
 				<select id="pronamic-pay-test-payment-methods" name="pronamic_pay_test_payment_method">
61 61
 					<?php
62 62
 
63
-					foreach ( $payment_methods['choices'][0]['options'] as $payment_method => $method_name ) {
63
+					foreach ( $payment_methods[ 'choices' ][ 0 ][ 'options' ] as $payment_method => $method_name ) {
64 64
 						printf(
65 65
 							'<option value="%s">%s</option>',
66 66
 							esc_attr( $payment_method ),
@@ -77,12 +77,12 @@  discard block
 block discarded – undo
77 77
 
78 78
 			<tr class="pronamic-pay-cloack pronamic-pay-test-payment-method <?php echo esc_attr( $method ); ?>">
79 79
 				<th scope="row">
80
-					<?php echo esc_html( $input['label'] ); ?>
80
+					<?php echo esc_html( $input[ 'label' ] ); ?>
81 81
 				</th>
82 82
 				<td>
83 83
 					<?php
84 84
 
85
-					echo $input['html']; // WPCS: XSS ok.
85
+					echo $input[ 'html' ]; // WPCS: XSS ok.
86 86
 
87 87
 					?>
88 88
 				</td>
Please login to merge, or discard this patch.
views/ideal-test-cases.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -66,7 +66,7 @@  discard block
 block discarded – undo
66 66
 						sprintf(
67 67
 							/* translators: %s: formatted amount */
68 68
 							__( 'Transaction with <code>amount</code> = %s:', 'pronamic_ideal' ),
69
-							esc_html( IDeal::format_amount( $data['amount'] ) )
69
+							esc_html( IDeal::format_amount( $data[ 'amount' ] ) )
70 70
 						),
71 71
 						array(
72 72
 							'code' => array(),
@@ -76,7 +76,7 @@  discard block
 block discarded – undo
76 76
 					?>
77 77
 				</td>
78 78
 				<td>
79
-					<?php echo esc_html( $data['result'] ); ?>
79
+					<?php echo esc_html( $data[ 'result' ] ); ?>
80 80
 				</td>
81 81
 			</tr>
82 82
 
Please login to merge, or discard this patch.
views/eshop/settings-meta-box.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -15,7 +15,7 @@  discard block
 block discarded – undo
15 15
 	<?php $eshop_metabox_plugin->show_img( 'pronamic_ideal' ); ?>
16 16
 
17 17
 	<p class="cbox">
18
-		<input id="eshop_method_pronamic_ideal" name="eshop_method[]" type="checkbox" value="pronamic_ideal" <?php checked( in_array( 'pronamic_ideal', (array) $eshopoptions['method'], true ) ); ?> />
18
+		<input id="eshop_method_pronamic_ideal" name="eshop_method[]" type="checkbox" value="pronamic_ideal" <?php checked( in_array( 'pronamic_ideal', (array) $eshopoptions[ 'method' ], true ) ); ?> />
19 19
 
20 20
 		<label for="eshop_method_pronamic_ideal" class="eshopmethod">
21 21
 			<?php esc_html_e( 'Accept payment by iDEAL', 'pronamic_ideal' ); ?>
@@ -30,7 +30,7 @@  discard block
 block discarded – undo
30 30
 
31 31
 	\Pronamic\WordPress\Pay\Admin\AdminModule::dropdown_configs( array(
32 32
 		'name'     => 'eshop_pronamic_ideal_config_id',
33
-		'selected' => @$eshopoptions['pronamic_ideal']['config_id'],
33
+		'selected' => @$eshopoptions[ 'pronamic_ideal' ][ 'config_id' ],
34 34
 	) );
35 35
 
36 36
 	?>
Please login to merge, or discard this patch.