Passed
Push — develop ( c92efd...038ff5 )
by Reüel
04:32
created
classes/AbstractDataStoreCPT.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -36,7 +36,7 @@
 block discarded – undo
36 36
 	 * @return string
37 37
 	 */
38 38
 	private function get_meta_key( $key ) {
39
-		return $this->meta_key_prefix . $key;
39
+		return $this->meta_key_prefix.$key;
40 40
 	}
41 41
 
42 42
 	/**
Please login to merge, or discard this patch.
classes/Subscriptions/Subscription.php 1 patch
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -380,7 +380,7 @@  discard block
 block discarded – undo
380 380
 	 * @throws \Exception    Throws an Exception when the `interval_spec` cannot be parsed as an interval.
381 381
 	 */
382 382
 	public function get_date_interval() {
383
-		$interval_spec = 'P' . $this->interval . $this->interval_period;
383
+		$interval_spec = 'P'.$this->interval.$this->interval_period;
384 384
 
385 385
 		$interval = new DateInterval( $interval_spec );
386 386
 
@@ -509,7 +509,7 @@  discard block
 block discarded – undo
509 509
 	 * @return string
510 510
 	 */
511 511
 	public function get_meta( $key ) {
512
-		$key = '_pronamic_subscription_' . $key;
512
+		$key = '_pronamic_subscription_'.$key;
513 513
 
514 514
 		return get_post_meta( $this->id, $key, true );
515 515
 	}
@@ -523,7 +523,7 @@  discard block
 block discarded – undo
523 523
 	 * @return boolean        True on successful update, false on failure.
524 524
 	 */
525 525
 	public function set_meta( $key, $value = false ) {
526
-		$key = '_pronamic_subscription_' . $key;
526
+		$key = '_pronamic_subscription_'.$key;
527 527
 
528 528
 		if ( $value instanceof DateTime ) {
529 529
 			$value = $value->format( 'Y-m-d H:i:s' );
@@ -548,7 +548,7 @@  discard block
 block discarded – undo
548 548
 
549 549
 		if ( $payment ) {
550 550
 			$description = apply_filters( 'pronamic_payment_source_description', $description, $payment );
551
-			$description = apply_filters( 'pronamic_payment_source_description_' . $this->source, $description, $payment );
551
+			$description = apply_filters( 'pronamic_payment_source_description_'.$this->source, $description, $payment );
552 552
 		}
553 553
 
554 554
 		return $description;
@@ -566,7 +566,7 @@  discard block
 block discarded – undo
566 566
 
567 567
 		if ( $payment ) {
568 568
 			$url = apply_filters( 'pronamic_payment_source_url', $url, $payment );
569
-			$url = apply_filters( 'pronamic_payment_source_url_' . $this->source, $url, $payment );
569
+			$url = apply_filters( 'pronamic_payment_source_url_'.$this->source, $url, $payment );
570 570
 		}
571 571
 
572 572
 		return $url;
@@ -641,7 +641,7 @@  discard block
 block discarded – undo
641 641
 		$payments = $this->get_payments();
642 642
 
643 643
 		if ( count( $payments ) > 0 ) {
644
-			return $payments[0];
644
+			return $payments[ 0 ];
645 645
 		}
646 646
 
647 647
 		return null;
@@ -897,7 +897,7 @@  discard block
 block discarded – undo
897 897
 	 * @param array $meta The meta data to update.
898 898
 	 */
899 899
 	public function update_meta( $meta ) {
900
-		if ( ! is_array( $meta ) || count( $meta ) === 0 ) {
900
+		if ( !is_array( $meta ) || count( $meta ) === 0 ) {
901 901
 			return;
902 902
 		}
903 903
 
Please login to merge, or discard this patch.
classes/Payments/PaymentTestData.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -152,7 +152,7 @@  discard block
 block discarded – undo
152 152
 	public function get_subscription() {
153 153
 		$test_subscription = filter_input( INPUT_POST, 'pronamic_pay_test_subscription', FILTER_VALIDATE_BOOLEAN );
154 154
 
155
-		if ( ! $test_subscription ) {
155
+		if ( !$test_subscription ) {
156 156
 			return false;
157 157
 		}
158 158
 
@@ -177,7 +177,7 @@  discard block
 block discarded – undo
177 177
 			case 'count':
178 178
 				$count = filter_input( INPUT_POST, 'pronamic_pay_ends_on_count', FILTER_VALIDATE_INT );
179 179
 
180
-				if ( ! empty( $count ) ) {
180
+				if ( !empty( $count ) ) {
181 181
 					$times = $count;
182 182
 				}
183 183
 
@@ -185,7 +185,7 @@  discard block
 block discarded – undo
185 185
 			case 'date':
186 186
 				$end_date = filter_input( INPUT_POST, 'pronamic_pay_ends_on_date', FILTER_SANITIZE_STRING );
187 187
 
188
-				if ( ! empty( $end_date ) ) {
188
+				if ( !empty( $end_date ) ) {
189 189
 					/* translators: 1: interval, 2: interval period */
190 190
 					$interval_spec = sprintf( 'P%1$s%2$s', $interval, Core_Util::to_period( $interval_period ) );
191 191
 
Please login to merge, or discard this patch.
admin/meta-box-notes.php 2 patches
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -8,11 +8,11 @@
 block discarded – undo
8 8
  * @package   Pronamic\WordPress\Pay
9 9
  */
10 10
 
11
-if ( ! isset( $notes ) ) {
11
+if ( !isset( $notes ) ) {
12 12
 	return;
13 13
 }
14 14
 
15
-if ( ! is_array( $notes ) ) {
15
+if ( !is_array( $notes ) ) {
16 16
 	return;
17 17
 }
18 18
 
Please login to merge, or discard this patch.
Braces   +5 added lines, -2 removed lines patch added patch discarded remove patch
@@ -20,12 +20,15 @@
 block discarded – undo
20 20
 
21 21
 	<?php esc_html_e( 'No notes found.', 'pronamic_ideal' ); ?>
22 22
 
23
-<?php else : ?>
23
+<?php else {
24
+	: ?>
24 25
 
25 26
 	<table class="pronamic-pay-table widefat">
26 27
 		<thead>
27 28
 			<tr>
28
-				<th scope="col"><?php esc_html_e( 'Date', 'pronamic_ideal' ); ?></th>
29
+				<th scope="col"><?php esc_html_e( 'Date', 'pronamic_ideal' );
30
+}
31
+?></th>
29 32
 				<th scope="col"><?php esc_html_e( 'Note', 'pronamic_ideal' ); ?></th>
30 33
 				<th scope="col"><?php esc_html_e( 'User', 'pronamic_ideal' ); ?></th>
31 34
 			</tr>
Please login to merge, or discard this patch.
admin/meta-box-subscription-payments.php 2 patches
Braces   +5 added lines, -2 removed lines patch added patch discarded remove patch
@@ -26,13 +26,16 @@
 block discarded – undo
26 26
 
27 27
 	<?php esc_html_e( 'No payments found.', 'pronamic_ideal' ); ?>
28 28
 
29
-<?php else : ?>
29
+<?php else {
30
+	: ?>
30 31
 
31 32
 	<table class="pronamic-pay-table widefat">
32 33
 		<thead>
33 34
 			<tr>
34 35
 				<th scope="col">
35
-					<span class="pronamic-pay-tip pronamic-pay-icon pronamic-pay-status" title="<?php esc_attr_e( 'Status', 'pronamic_ideal' ); ?>"><?php esc_html_e( 'Status', 'pronamic_ideal' ); ?></span>
36
+					<span class="pronamic-pay-tip pronamic-pay-icon pronamic-pay-status" title="<?php esc_attr_e( 'Status', 'pronamic_ideal' );
37
+}
38
+?>"><?php esc_html_e( 'Status', 'pronamic_ideal' ); ?></span>
36 39
 				</th>
37 40
 				<th scope="col"><?php esc_html_e( 'Payment', 'pronamic_ideal' ); ?></th>
38 41
 				<th scope="col"><?php esc_html_e( 'Transaction', 'pronamic_ideal' ); ?></th>
Please login to merge, or discard this patch.
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -56,19 +56,19 @@
 block discarded – undo
56 56
 
57 57
 				<tr>
58 58
 					<td>
59
-						<?php do_action( 'manage_' . $post_type . '_posts_custom_column', 'pronamic_payment_status', $payment_id ); ?>
59
+						<?php do_action( 'manage_'.$post_type.'_posts_custom_column', 'pronamic_payment_status', $payment_id ); ?>
60 60
 					</td>
61 61
 					<td>
62
-						<?php do_action( 'manage_' . $post_type . '_posts_custom_column', 'pronamic_payment_title', $payment_id ); ?>
62
+						<?php do_action( 'manage_'.$post_type.'_posts_custom_column', 'pronamic_payment_title', $payment_id ); ?>
63 63
 					</td>
64 64
 					<td>
65
-						<?php do_action( 'manage_' . $post_type . '_posts_custom_column', 'pronamic_payment_transaction', $payment_id ); ?>
65
+						<?php do_action( 'manage_'.$post_type.'_posts_custom_column', 'pronamic_payment_transaction', $payment_id ); ?>
66 66
 					</td>
67 67
 					<td>
68
-						<?php do_action( 'manage_' . $post_type . '_posts_custom_column', 'pronamic_payment_amount', $payment_id ); ?>
68
+						<?php do_action( 'manage_'.$post_type.'_posts_custom_column', 'pronamic_payment_amount', $payment_id ); ?>
69 69
 					</td>
70 70
 					<td>
71
-						<?php do_action( 'manage_' . $post_type . '_posts_custom_column', 'pronamic_payment_date', $payment_id ); ?>
71
+						<?php do_action( 'manage_'.$post_type.'_posts_custom_column', 'pronamic_payment_date', $payment_id ); ?>
72 72
 					</td>
73 73
 					<td>
74 74
 						<?php echo empty( $payment->start_date ) ? '—' : esc_html( $payment->start_date->format_i18n() ); ?>
Please login to merge, or discard this patch.
classes/Util.php 1 patch
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -35,7 +35,7 @@  discard block
 block discarded – undo
35 35
 	public static function remote_get_body( $url, $required_response_code = 200, array $args = array() ) {
36 36
 		$result = wp_remote_request( $url, $args );
37 37
 
38
-		if ( ! is_array( $result ) ) {
38
+		if ( !is_array( $result ) ) {
39 39
 			return $result;
40 40
 		}
41 41
 
@@ -190,7 +190,7 @@  discard block
 block discarded – undo
190 190
 		// @see https://en.wikipedia.org/wiki/Non-breaking_space#Keyboard_entry_methods
191 191
 		$non_breaking_space = ' ';
192 192
 
193
-		return '' . $currency_symbol . $non_breaking_space . number_format_i18n( $float, 2 );
193
+		return ''.$currency_symbol.$non_breaking_space.number_format_i18n( $float, 2 );
194 194
 	}
195 195
 
196 196
 	/**
@@ -268,7 +268,7 @@  discard block
 block discarded – undo
268 268
 	 * @return string
269 269
 	 */
270 270
 	public static function build_url( $url, array $parameters ) {
271
-		return $url . '?' . _http_build_query( $parameters, null, '&' );
271
+		return $url.'?'._http_build_query( $parameters, null, '&' );
272 272
 	}
273 273
 
274 274
 	/**
@@ -320,14 +320,14 @@  discard block
 block discarded – undo
320 320
 
321 321
 		if ( is_array( $groups ) ) {
322 322
 			foreach ( $groups as $group ) {
323
-				$optgroup = isset( $group['name'] ) && ! empty( $group['name'] );
323
+				$optgroup = isset( $group[ 'name' ] ) && !empty( $group[ 'name' ] );
324 324
 
325 325
 				if ( $optgroup ) {
326
-					$html .= '<optgroup label="' . $group['name'] . '">';
326
+					$html .= '<optgroup label="'.$group[ 'name' ].'">';
327 327
 				}
328 328
 
329
-				foreach ( $group['options'] as $value => $label ) {
330
-					$html .= '<option value="' . $value . '" ' . selected( $selected_value, $value, false ) . '>' . $label . '</option>';
329
+				foreach ( $group[ 'options' ] as $value => $label ) {
330
+					$html .= '<option value="'.$value.'" '.selected( $selected_value, $value, false ).'>'.$label.'</option>';
331 331
 				}
332 332
 
333 333
 				if ( $optgroup ) {
Please login to merge, or discard this patch.
classes/GatewayIntegrations.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -76,7 +76,7 @@  discard block
 block discarded – undo
76 76
 			'test' => 'https://abnamro-test.ideal-payment.de/',
77 77
 			'live' => 'https://abnamro.ideal-payment.de/',
78 78
 		);
79
-		$abn_amro_ideal_zelfbouw_v3->provider      = 'abnamro';
79
+		$abn_amro_ideal_zelfbouw_v3->provider = 'abnamro';
80 80
 
81 81
 		// Deutsche Bank - iDEAL via Ogone.
82 82
 		$deutsche_bank_ideal_ogone = new Gateways\Ingenico\OrderStandardEasy\Integration();
@@ -94,7 +94,7 @@  discard block
 block discarded – undo
94 94
 			'test' => 'https://myideal.test.db.com/',
95 95
 			'live' => 'https://myideal.db.com/',
96 96
 		);
97
-		$deutsche_bank_ideal_expert_v3->provider      = 'deutschebank';
97
+		$deutsche_bank_ideal_expert_v3->provider = 'deutschebank';
98 98
 
99 99
 		// Fibonacci ORANGE.
100 100
 		$fibonacci_orange = new Gateways\Icepay\Integration();
Please login to merge, or discard this patch.
tests/Payments/PaymentTest.php 1 patch
Spacing   +26 added lines, -26 removed lines patch added patch discarded remove patch
@@ -27,7 +27,7 @@  discard block
 block discarded – undo
27 27
 	public function test_construct() {
28 28
 		$payment = new Payment();
29 29
 
30
-		$this->assertInstanceOf( __NAMESPACE__ . '\Payment', $payment );
30
+		$this->assertInstanceOf( __NAMESPACE__.'\Payment', $payment );
31 31
 	}
32 32
 
33 33
 	/**
@@ -45,9 +45,9 @@  discard block
 block discarded – undo
45 45
 
46 46
 	public function get_and_set_provider() {
47 47
 		return array(
48
-			array( 'set_id',             'get_id',             uniqid()    ),
49
-			array( 'set_transaction_id', 'get_transaction_id', uniqid()    ),
50
-			array( 'set_status',         'get_status',         'completed' ),
48
+			array( 'set_id', 'get_id', uniqid() ),
49
+			array( 'set_transaction_id', 'get_transaction_id', uniqid() ),
50
+			array( 'set_status', 'get_status', 'completed' ),
51 51
 		);
52 52
 	}
53 53
 
@@ -66,11 +66,11 @@  discard block
 block discarded – undo
66 66
 
67 67
 	public function set_provider() {
68 68
 		return array(
69
-			array( 'set_consumer_name',           'consumer_name',           'John Doe' ),
69
+			array( 'set_consumer_name', 'consumer_name', 'John Doe' ),
70 70
 			array( 'set_consumer_account_number', 'consumer_account_number', '1086.34.779' ),
71
-			array( 'set_consumer_iban',           'consumer_iban',           'NL56 RABO 0108 6347 79' ),
72
-			array( 'set_consumer_bic',            'consumer_bic',            'RABONL2U' ),
73
-			array( 'set_consumer_city',           'consumer_city',           'Drachten' ),
71
+			array( 'set_consumer_iban', 'consumer_iban', 'NL56 RABO 0108 6347 79' ),
72
+			array( 'set_consumer_bic', 'consumer_bic', 'RABONL2U' ),
73
+			array( 'set_consumer_city', 'consumer_city', 'Drachten' ),
74 74
 		);
75 75
 	}
76 76
 
@@ -89,25 +89,25 @@  discard block
 block discarded – undo
89 89
 
90 90
 	public function get_provider() {
91 91
 		return array(
92
-			array( 'order_id',            'get_order_id',            1234 ),
93
-			array( 'amount',              'get_amount',              89.95 ),
94
-			array( 'currency',            'get_currency',            'EUR' ),
95
-			array( 'method',              'get_method',              'ideal' ),
96
-			array( 'issuer',              'get_issuer',              'ideal_KNABNL2H' ),
97
-			array( 'language',            'get_language',            'nl' ),
98
-			array( 'locale',              'get_locale',              'nl_NL' ),
99
-			array( 'description',         'get_description',         'Lorem ipsum dolor sit amet, consectetur.' ),
100
-			array( 'email',               'get_email',               '[email protected]' ),
101
-			array( 'first_name',          'get_first_name',          'John' ),
102
-			array( 'last_name',           'get_last_name',           'Doe' ),
103
-			array( 'customer_name',       'get_customer_name',       'John Doe' ),
104
-			array( 'address',             'get_address',             'Burgemeester Wuiteweg 39b' ),
105
-			array( 'city',                'get_city',                'Drachten' ),
106
-			array( 'zip',                 'get_zip',                 '9203 KA' ),
107
-			array( 'country',             'get_country',             'NL' ),
108
-			array( 'telephone_number',    'get_telephone_number',    '1234567890' ),
92
+			array( 'order_id', 'get_order_id', 1234 ),
93
+			array( 'amount', 'get_amount', 89.95 ),
94
+			array( 'currency', 'get_currency', 'EUR' ),
95
+			array( 'method', 'get_method', 'ideal' ),
96
+			array( 'issuer', 'get_issuer', 'ideal_KNABNL2H' ),
97
+			array( 'language', 'get_language', 'nl' ),
98
+			array( 'locale', 'get_locale', 'nl_NL' ),
99
+			array( 'description', 'get_description', 'Lorem ipsum dolor sit amet, consectetur.' ),
100
+			array( 'email', 'get_email', '[email protected]' ),
101
+			array( 'first_name', 'get_first_name', 'John' ),
102
+			array( 'last_name', 'get_last_name', 'Doe' ),
103
+			array( 'customer_name', 'get_customer_name', 'John Doe' ),
104
+			array( 'address', 'get_address', 'Burgemeester Wuiteweg 39b' ),
105
+			array( 'city', 'get_city', 'Drachten' ),
106
+			array( 'zip', 'get_zip', '9203 KA' ),
107
+			array( 'country', 'get_country', 'NL' ),
108
+			array( 'telephone_number', 'get_telephone_number', '1234567890' ),
109 109
 			array( 'analytics_client_id', 'get_analytics_client_id', 'GA1.2.1234567890.1234567890' ),
110
-			array( 'entrance_code',       'get_entrance_code',       uniqid() ),
110
+			array( 'entrance_code', 'get_entrance_code', uniqid() ),
111 111
 		);
112 112
 	}
113 113
 
Please login to merge, or discard this patch.
classes/DateTimeZone.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
 	public static function get_default() {
31 31
 		$timezone_string = get_option( 'timezone_string' );
32 32
 
33
-		if ( ! empty( $timezone_string ) ) {
33
+		if ( !empty( $timezone_string ) ) {
34 34
 			return new DateTimeZone( $timezone_string );
35 35
 		}
36 36
 
Please login to merge, or discard this patch.