Passed
Push — develop ( 6715ca...5be752 )
by Remco
03:51
created
tests/bootstrap.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -1,16 +1,16 @@
 block discarded – undo
1 1
 <?php
2 2
 
3 3
 $_tests_dir = getenv( 'WP_TESTS_DIR' );
4
-if ( ! $_tests_dir ) {
4
+if ( !$_tests_dir ) {
5 5
 	$_tests_dir = '/tmp/wordpress-tests-lib';
6 6
 }
7 7
 
8
-require_once $_tests_dir . '/includes/functions.php';
8
+require_once $_tests_dir.'/includes/functions.php';
9 9
 
10 10
 function _manually_load_plugin() {
11
-	require dirname( __FILE__ ) . '/../pronamic-ideal.php';
11
+	require dirname( __FILE__ ).'/../pronamic-ideal.php';
12 12
 }
13 13
 
14 14
 tests_add_filter( 'muplugins_loaded', '_manually_load_plugin' );
15 15
 
16
-require $_tests_dir . '/includes/bootstrap.php';
16
+require $_tests_dir.'/includes/bootstrap.php';
Please login to merge, or discard this patch.
pronamic-ideal.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -60,10 +60,10 @@  discard block
 block discarded – undo
60 60
 /**
61 61
  * Autoload.
62 62
  */
63
-$loader = require_once plugin_dir_path( __FILE__ ) . 'vendor/autoload.php';
63
+$loader = require_once plugin_dir_path( __FILE__ ).'vendor/autoload.php';
64 64
 
65 65
 if ( defined( 'PRONAMIC_PAY_DEBUG' ) && PRONAMIC_PAY_DEBUG ) {
66
-	foreach ( glob( __DIR__ . '/repositories/*/*/composer.json' ) as $file ) {
66
+	foreach ( glob( __DIR__.'/repositories/*/*/composer.json' ) as $file ) {
67 67
 		$content = file_get_contents( $file );
68 68
 
69 69
 		$object = json_decode( $content );
@@ -72,7 +72,7 @@  discard block
 block discarded – undo
72 72
 			foreach ( $object->autoload as $type => $map ) {
73 73
 				if ( 'psr-4' === $type ) {
74 74
 					foreach ( $map as $prefix => $path ) {
75
-						$loader->addPsr4( $prefix, dirname( $file ) . '/' . $path, true );
75
+						$loader->addPsr4( $prefix, dirname( $file ).'/'.$path, true );
76 76
 					}
77 77
 				}
78 78
 			}
Please login to merge, or discard this patch.
views/redirect-message.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -16,7 +16,7 @@
 block discarded – undo
16 16
 
17 17
 wp_register_style(
18 18
 	'pronamic-pay-redirect',
19
-	plugins_url( 'css/redirect' . $min . '.css', Plugin::$file ),
19
+	plugins_url( 'css/redirect'.$min.'.css', Plugin::$file ),
20 20
 	array(),
21 21
 	$pronamic_ideal->get_version()
22 22
 );
Please login to merge, or discard this patch.
classes/Currency.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -28,7 +28,7 @@
 block discarded – undo
28 28
 	public static function transform_code_to_number( $code ) {
29 29
 		$currencies = array();
30 30
 
31
-		$file = dirname( Plugin::$file ) . '/other/dl_iso_table_a1.xml';
31
+		$file = dirname( Plugin::$file ).'/other/dl_iso_table_a1.xml';
32 32
 
33 33
 		$xml = simplexml_load_file( $file );
34 34
 
Please login to merge, or discard this patch.
classes/Settings.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -52,7 +52,7 @@  discard block
 block discarded – undo
52 52
 		);
53 53
 
54 54
 		foreach ( $no_trim_options as $option ) {
55
-			add_filter( 'sanitize_option_' . $option, array( $this, 'sanitize_option_dont_trim_posted_value' ), 10, 2 );
55
+			add_filter( 'sanitize_option_'.$option, array( $this, 'sanitize_option_dont_trim_posted_value' ), 10, 2 );
56 56
 		}
57 57
 	}
58 58
 
@@ -119,7 +119,7 @@  discard block
 block discarded – undo
119 119
 		register_setting(
120 120
 			'pronamic_pay', 'pronamic_pay_thousands_sep', array(
121 121
 				'type'              => 'string',
122
-				'default'           => $wp_locale->number_format['thousands_sep'],
122
+				'default'           => $wp_locale->number_format[ 'thousands_sep' ],
123 123
 				'sanitize_callback' => null,
124 124
 			)
125 125
 		);
@@ -132,7 +132,7 @@  discard block
 block discarded – undo
132 132
 		register_setting(
133 133
 			'pronamic_pay', 'pronamic_pay_decimal_sep', array(
134 134
 				'type'              => 'string',
135
-				'default'           => $wp_locale->number_format['decimal_point'],
135
+				'default'           => $wp_locale->number_format[ 'decimal_point' ],
136 136
 				'sanitize_callback' => null,
137 137
 			)
138 138
 		);
Please login to merge, or discard this patch.
classes/GoogleAnalyticsEcommerce.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -163,11 +163,11 @@  discard block
 block discarded – undo
163 163
 	private function get_client_id( Payment $payment ) {
164 164
 		$client_id = $payment->get_analytics_client_id();
165 165
 
166
-		if ( ! empty( $client_id ) ) {
166
+		if ( !empty( $client_id ) ) {
167 167
 			return $client_id;
168 168
 		}
169 169
 
170
-		if ( ! empty( $this->client_id ) ) {
170
+		if ( !empty( $this->client_id ) ) {
171 171
 			return $this->client_id;
172 172
 		}
173 173
 
@@ -228,12 +228,12 @@  discard block
 block discarded – undo
228 228
 
229 229
 		$ga = explode( '.', $ga_cookie );
230 230
 
231
-		if ( isset( $ga[2] ) && GoogleAnalyticsEcommerce::is_uuid( $ga[2] ) ) {
231
+		if ( isset( $ga[ 2 ] ) && GoogleAnalyticsEcommerce::is_uuid( $ga[ 2 ] ) ) {
232 232
 			// Use UUID from cookie.
233
-			$client_id = $ga[2];
234
-		} elseif ( isset( $ga[2], $ga[3] ) ) {
233
+			$client_id = $ga[ 2 ];
234
+		} elseif ( isset( $ga[ 2 ], $ga[ 3 ] ) ) {
235 235
 			// Older Google Client ID.
236
-			$client_id = sprintf( '%s.%s', $ga[2], $ga[3] );
236
+			$client_id = sprintf( '%s.%s', $ga[ 2 ], $ga[ 3 ] );
237 237
 		}
238 238
 
239 239
 		return $client_id;
Please login to merge, or discard this patch.
classes/Payments/PaymentData.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -219,13 +219,13 @@
 block discarded – undo
219 219
 	 * @return string
220 220
 	 */
221 221
 	public function get_subscription_id() {
222
-		if ( ! $this->get_subscription() ) {
222
+		if ( !$this->get_subscription() ) {
223 223
 			return;
224 224
 		}
225 225
 
226 226
 		$payment = get_pronamic_payment_by_meta( '_pronamic_payment_source_id', $this->get_subscription_source_id() );
227 227
 
228
-		if ( ! $payment ) {
228
+		if ( !$payment ) {
229 229
 			return;
230 230
 		}
231 231
 
Please login to merge, or discard this patch.
classes/Payments/Payment.php 1 patch
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -422,9 +422,9 @@  discard block
 block discarded – undo
422 422
 	 * @return string
423 423
 	 */
424 424
 	public function get_source_text() {
425
-		$text = $this->get_source() . '<br />' . $this->get_source_id();
425
+		$text = $this->get_source().'<br />'.$this->get_source_id();
426 426
 
427
-		$text = apply_filters( 'pronamic_payment_source_text_' . $this->get_source(), $text, $this );
427
+		$text = apply_filters( 'pronamic_payment_source_text_'.$this->get_source(), $text, $this );
428 428
 		$text = apply_filters( 'pronamic_payment_source_text', $text, $this );
429 429
 
430 430
 		return $text;
@@ -556,7 +556,7 @@  discard block
 block discarded – undo
556 556
 	 * @return mixed
557 557
 	 */
558 558
 	public function get_meta( $key ) {
559
-		$key = '_pronamic_payment_' . $key;
559
+		$key = '_pronamic_payment_'.$key;
560 560
 
561 561
 		return get_post_meta( $this->id, $key, true );
562 562
 	}
@@ -633,7 +633,7 @@  discard block
 block discarded – undo
633 633
 		$url = home_url( '/' );
634 634
 
635 635
 		$url = apply_filters( 'pronamic_payment_redirect_url', $url, $this );
636
-		$url = apply_filters( 'pronamic_payment_redirect_url_' . $this->source, $url, $this );
636
+		$url = apply_filters( 'pronamic_payment_redirect_url_'.$this->source, $url, $this );
637 637
 
638 638
 		return $url;
639 639
 	}
@@ -659,7 +659,7 @@  discard block
 block discarded – undo
659 659
 		$description = $this->source;
660 660
 
661 661
 		$description = apply_filters( 'pronamic_payment_source_description', $description, $this );
662
-		$description = apply_filters( 'pronamic_payment_source_description_' . $this->source, $description, $this );
662
+		$description = apply_filters( 'pronamic_payment_source_description_'.$this->source, $description, $this );
663 663
 
664 664
 		return $description;
665 665
 	}
@@ -673,7 +673,7 @@  discard block
 block discarded – undo
673 673
 		$url = null;
674 674
 
675 675
 		$url = apply_filters( 'pronamic_payment_source_url', $url, $this );
676
-		$url = apply_filters( 'pronamic_payment_source_url_' . $this->source, $url, $this );
676
+		$url = apply_filters( 'pronamic_payment_source_url_'.$this->source, $url, $this );
677 677
 
678 678
 		return $url;
679 679
 	}
@@ -690,7 +690,7 @@  discard block
 block discarded – undo
690 690
 		$gateway_id = get_post_meta( $config_id, '_pronamic_gateway_id', true );
691 691
 
692 692
 		$url = apply_filters( 'pronamic_payment_provider_url', $url, $this );
693
-		$url = apply_filters( 'pronamic_payment_provider_url_' . $gateway_id, $url, $this );
693
+		$url = apply_filters( 'pronamic_payment_provider_url_'.$gateway_id, $url, $this );
694 694
 
695 695
 		return $url;
696 696
 	}
Please login to merge, or discard this patch.
classes/LicenseManager.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -50,7 +50,7 @@  discard block
 block discarded – undo
50 50
 		$data = get_transient( 'pronamic_pay_license_data' );
51 51
 
52 52
 		if ( $data ) {
53
-			include $this->plugin->get_plugin_dir_path() . 'admin/notice-license.php';
53
+			include $this->plugin->get_plugin_dir_path().'admin/notice-license.php';
54 54
 
55 55
 			delete_transient( 'pronamic_pay_license_data' );
56 56
 		}
@@ -69,14 +69,14 @@  discard block
 block discarded – undo
69 69
 		if ( $newvalue !== $oldvalue ) {
70 70
 			delete_option( 'pronamic_pay_license_status' );
71 71
 
72
-			if ( ! empty( $oldvalue ) ) {
72
+			if ( !empty( $oldvalue ) ) {
73 73
 				$this->deactivate_license( $oldvalue );
74 74
 			}
75 75
 		}
76 76
 
77 77
 		delete_transient( 'pronamic_pay_license_data' );
78 78
 
79
-		if ( ! empty( $newvalue ) ) {
79
+		if ( !empty( $newvalue ) ) {
80 80
 			// Always try to activate the new license, it could be deactivated.
81 81
 			$this->activate_license( $newvalue );
82 82
 		}
Please login to merge, or discard this patch.