Passed
Push — master ( 60cf75...7ee9b2 )
by Brian
128:01 queued 122:23
created
includes/admin/class-getpaid-admin-profile.php 1 patch
Braces   +5 added lines, -2 removed lines patch added patch discarded remove patch
@@ -124,8 +124,11 @@
 block discarded – undo
124 124
 									</select>
125 125
 								<?php elseif ( ! empty( $field['type'] ) && 'checkbox' === $field['type'] ) : ?>
126 126
 									<input type="checkbox" name="<?php echo esc_attr( $key ); ?>" id="<?php echo esc_attr( $key ); ?>" value="1" class="<?php echo esc_attr( $field['class'] ); ?>" <?php checked( (int) get_user_meta( $user->ID, $key, true ), 1, true ); ?> />
127
-								<?php else : ?>
128
-									<input type="text" name="<?php echo esc_attr( $key ); ?>" id="<?php echo esc_attr( $key ); ?>" value="<?php echo esc_attr( $this->get_user_meta( $user->ID, $key ) ); ?>" class="<?php echo ( ! empty( $field['class'] ) ? esc_attr( $field['class'] ) : 'regular-text' ); ?>" />
127
+								<?php else {
128
+    : ?>
129
+									<input type="text" name="<?php echo esc_attr( $key );
130
+}
131
+?>" id="<?php echo esc_attr( $key ); ?>" value="<?php echo esc_attr( $this->get_user_meta( $user->ID, $key ) ); ?>" class="<?php echo ( ! empty( $field['class'] ) ? esc_attr( $field['class'] ) : 'regular-text' ); ?>" />
129 132
 								<?php endif; ?>
130 133
 								<p class="description"><?php echo wp_kses_post( $field['description'] ); ?></p>
131 134
 							</td>
Please login to merge, or discard this patch.
vendor/ayecode/wp-ayecode-ui/includes/ayecode-ui-settings.php 1 patch
Braces   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -542,12 +542,12 @@
 block discarded – undo
542 542
 				is_admin() ? wp_enqueue_script( 'bootstrap-js-bundle', '', null, null, true ) : wp_enqueue_script( 'bootstrap-js-bundle');
543 543
 				$script = $this->inline_script();
544 544
 				wp_add_inline_script( 'bootstrap-js-bundle', $script );
545
-			}elseif($this->settings[$js_setting]=='popper'){
545
+			} elseif($this->settings[$js_setting]=='popper'){
546 546
 				$url = $this->url.'assets/js/popper.min.js';
547 547
 				wp_register_script( 'bootstrap-js-popper', $url, array('jquery'), $this->latest );
548 548
 				wp_enqueue_script( 'bootstrap-js-popper' );
549 549
 				$load_inline = true;
550
-			}else{
550
+			} else{
551 551
 				$load_inline = true;
552 552
 			}
553 553
 
Please login to merge, or discard this patch.
vendor/ayecode/wp-super-duper/wp-super-duper.php 1 patch
Braces   +8 added lines, -9 removed lines patch added patch discarded remove patch
@@ -661,7 +661,7 @@  discard block
 block discarded – undo
661 661
 				<?php
662 662
 				if(! empty( $insert_shortcode_function )){
663 663
 					echo $insert_shortcode_function;
664
-				}else{
664
+				} else{
665 665
 
666 666
 				/**
667 667
 				 * Function for super duper insert shortcode.
@@ -1645,7 +1645,7 @@  discard block
 block discarded – undo
1645 1645
 					var prev_attributes = [];
1646 1646
 
1647 1647
 					var term_query_type = '';
1648
-					var post_type_rest_slugs = <?php if(! empty( $this->arguments ) && isset($this->arguments['post_type']['onchange_rest']['values'])){echo "[".json_encode($this->arguments['post_type']['onchange_rest']['values'])."]";}else{echo "[]";} ?>;
1648
+					var post_type_rest_slugs = <?php if(! empty( $this->arguments ) && isset($this->arguments['post_type']['onchange_rest']['values'])){echo "[".json_encode($this->arguments['post_type']['onchange_rest']['values'])."]";} else{echo "[]";} ?>;
1649 1649
 					const taxonomies_<?php echo str_replace("-","_", $this->id);?> = [{label: "Please wait", value: 0}];
1650 1650
 
1651 1651
 					/**
@@ -1774,7 +1774,7 @@  discard block
 block discarded – undo
1774 1774
 								}
1775 1775
 								if('post_type' in prev_attributes[props.id] && 'category' in prev_attributes[props.id] && $pt != term_query_type ){
1776 1776
 									term_query_type = $pt;
1777
-									wp.apiFetch({path: "<?php if(isset($this->arguments['post_type']['onchange_rest']['path'])){echo $this->arguments['post_type']['onchange_rest']['path'];}else{'/wp/v2/"+$value+"/categories';} ?>"}).then(terms => {
1777
+									wp.apiFetch({path: "<?php if(isset($this->arguments['post_type']['onchange_rest']['path'])){echo $this->arguments['post_type']['onchange_rest']['path'];} else{'/wp/v2/"+$value+"/categories';} ?>"}).then(terms => {
1778 1778
 										while (taxonomies_<?php echo str_replace("-","_", $this->id);?>.length) {
1779 1779
 										taxonomies_<?php echo str_replace("-","_", $this->id);?>.pop();
1780 1780
 									}
@@ -1922,7 +1922,7 @@  discard block
 block discarded – undo
1922 1922
 									$panel_count ++;
1923 1923
 
1924 1924
 									}
1925
-									}else {
1925
+									} else {
1926 1926
 									?>
1927 1927
 									el(wp.components.PanelBody, {
1928 1928
 											title: '<?php esc_attr_e( "Settings" ); ?>',
@@ -1946,7 +1946,7 @@  discard block
 block discarded – undo
1946 1946
 								// If the user sets block-output array then build it
1947 1947
 								if ( ! empty( $this->options['block-output'] ) ) {
1948 1948
 								$this->block_element( $this->options['block-output'] );
1949
-							}else{
1949
+							} else{
1950 1950
 								// if no block-output is set then we try and get the shortcode html output via ajax.
1951 1951
 								?>
1952 1952
 								el('div', {
@@ -2016,7 +2016,7 @@  discard block
 block discarded – undo
2016 2016
 							?>
2017 2017
 							return content;
2018 2018
 							<?php
2019
-							}else{
2019
+							} else{
2020 2020
 							?>
2021 2021
 							var block_wrap = 'div';
2022 2022
 							if (attr.hasOwnProperty("block_wrap")) {
@@ -2121,8 +2121,7 @@  discard block
 block discarded – undo
2121 2121
                             $key: value
2122 2122
                         });
2123 2123
                     },";
2124
-			}
2125
-			elseif ( $args['type'] == 'checkbox' ) {
2124
+			} elseif ( $args['type'] == 'checkbox' ) {
2126 2125
 				$type = 'CheckboxControl';
2127 2126
 				$extra .= "checked: props.attributes.$key,";
2128 2127
 				$onchange = "props.setAttributes({ $key: ! props.attributes.$key } )";
@@ -2133,7 +2132,7 @@  discard block
 block discarded – undo
2133 2132
 
2134 2133
 				if($args['name'] == 'category' && !empty($args['post_type_linked'])){
2135 2134
 					$options .= "options: taxonomies_".str_replace("-","_", $this->id).",";
2136
-				}else {
2135
+				} else {
2137 2136
 
2138 2137
 					if ( ! empty( $args['options'] ) ) {
2139 2138
 						$options .= "options: [";
Please login to merge, or discard this patch.
includes/wpinv-template-functions.php 1 patch
Braces   +12 added lines, -8 removed lines patch added patch discarded remove patch
@@ -218,8 +218,9 @@  discard block
 block discarded – undo
218 218
 
219 219
 	// Setup possible parts
220 220
 	$templates = array();
221
-	if ( isset( $name ) )
222
-		$templates[] = $slug . '-' . $name . '.php';
221
+	if ( isset( $name ) ) {
222
+			$templates[] = $slug . '-' . $name . '.php';
223
+	}
223 224
 	$templates[] = $slug . '.php';
224 225
 
225 226
 	// Allow template parts to be filtered
@@ -237,8 +238,9 @@  discard block
 block discarded – undo
237 238
 	foreach ( (array)$template_names as $template_name ) {
238 239
 
239 240
 		// Continue if template is empty
240
-		if ( empty( $template_name ) )
241
-			continue;
241
+		if ( empty( $template_name ) ) {
242
+					continue;
243
+		}
242 244
 
243 245
 		// Trim off any slashes from the template name
244 246
 		$template_name = ltrim( $template_name, '/' );
@@ -257,8 +259,9 @@  discard block
 block discarded – undo
257 259
 		}
258 260
 	}
259 261
 
260
-	if ( ( true == $load ) && ! empty( $located ) )
261
-		load_template( $located, $require_once );
262
+	if ( ( true == $load ) && ! empty( $located ) ) {
263
+			load_template( $located, $require_once );
264
+	}
262 265
 
263 266
 	return $located;
264 267
 }
@@ -336,8 +339,9 @@  discard block
 block discarded – undo
336 339
 function wpinv_html_dropdown( $name = 'wpinv_discounts', $selected = 0, $status = '' ) {
337 340
     $args = array( 'nopaging' => true );
338 341
 
339
-    if ( ! empty( $status ) )
340
-        $args['post_status'] = $status;
342
+    if ( ! empty( $status ) ) {
343
+            $args['post_status'] = $status;
344
+    }
341 345
 
342 346
     $discounts = wpinv_get_discounts( $args );
343 347
     $options   = array();
Please login to merge, or discard this patch.
includes/class-wpinv-invoice.php 1 patch
Braces   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -156,7 +156,7 @@
 block discarded – undo
156 156
 			$this->set_id( $invoice_id );
157 157
 		} elseif ( is_scalar( $invoice ) && $invoice_id = self::get_invoice_id_by_field( $invoice, 'transaction_id' ) ) {
158 158
 			$this->set_id( $invoice_id );
159
-		}else {
159
+		} else {
160 160
 			$this->set_object_read( true );
161 161
 		}
162 162
 
Please login to merge, or discard this patch.
includes/libraries/wpinv-euvat/class-wpinv-euvat.php 1 patch
Braces   +7 added lines, -5 removed lines patch added patch discarded remove patch
@@ -712,7 +712,7 @@  discard block
 block discarded – undo
712 712
                 if ( !empty( $load_xml ) && !empty( $load_xml->geoplugin_countryCode ) ) {
713 713
                     $wpinv_ip_address_country = (string)$load_xml->geoplugin_countryCode;
714 714
                 }
715
-            }elseif(!empty( $ip )){
715
+            } elseif(!empty( $ip )){
716 716
                 $url = 'http://ip-api.com/json/' . $ip;
717 717
                 $response = wp_remote_get($url);
718 718
 
@@ -1513,16 +1513,18 @@  discard block
 block discarded – undo
1513 1513
 
1514 1514
         if ( !empty( $tax_rates ) ) {
1515 1515
             foreach ( $tax_rates as $key => $tax_rate ) {
1516
-                if ( $country != $tax_rate['country'] )
1517
-                    continue;
1516
+                if ( $country != $tax_rate['country'] ) {
1517
+                                    continue;
1518
+                }
1518 1519
 
1519 1520
                 if ( !empty( $tax_rate['global'] ) ) {
1520 1521
                     if ( 0 !== $tax_rate['rate'] || !empty( $tax_rate['rate'] ) ) {
1521 1522
                         $rate = number_format( $tax_rate['rate'], 4 );
1522 1523
                     }
1523 1524
                 } else {
1524
-                    if ( empty( $tax_rate['state'] ) || strtolower( $state ) != strtolower( $tax_rate['state'] ) )
1525
-                        continue;
1525
+                    if ( empty( $tax_rate['state'] ) || strtolower( $state ) != strtolower( $tax_rate['state'] ) ) {
1526
+                                            continue;
1527
+                    }
1526 1528
 
1527 1529
                     $state_rate = $tax_rate['rate'];
1528 1530
                     if ( 0 !== $state_rate || !empty( $state_rate ) ) {
Please login to merge, or discard this patch.
includes/wpinv-general-functions.php 1 patch
Braces   +15 added lines, -10 removed lines patch added patch discarded remove patch
@@ -87,8 +87,9 @@  discard block
 block discarded – undo
87 87
     
88 88
     if ( !empty( $args ) ) {
89 89
         // Check for backward compatibility
90
-        if ( is_string( $args ) )
91
-            $args = str_replace( '?', '', $args );
90
+        if ( is_string( $args ) ) {
91
+                    $args = str_replace( '?', '', $args );
92
+        }
92 93
 
93 94
         $args = wp_parse_args( $args );
94 95
 
@@ -108,8 +109,9 @@  discard block
 block discarded – undo
108 109
 
109 110
 	if ( !empty( $args ) ) {
110 111
 		// Check for backward compatibility
111
-		if ( is_string( $args ) )
112
-			$args = str_replace( '?', '', $args );
112
+		if ( is_string( $args ) ) {
113
+					$args = str_replace( '?', '', $args );
114
+		}
113 115
 
114 116
 		$args = wp_parse_args( $args );
115 117
 
@@ -132,8 +134,9 @@  discard block
 block discarded – undo
132 134
 
133 135
 	if ( ! empty( $args ) ) {
134 136
 		// Check for backward compatibility
135
-		if ( is_string( $args ) )
136
-			$args = str_replace( '?', '', $args );
137
+		if ( is_string( $args ) ) {
138
+					$args = str_replace( '?', '', $args );
139
+		}
137 140
 
138 141
 		$args = wp_parse_args( $args );
139 142
 
@@ -149,8 +152,9 @@  discard block
 block discarded – undo
149 152
 	$success_page = wpinv_get_option( 'success_page', 0 );
150 153
 	$success_page = get_permalink( $success_page );
151 154
 
152
-	if ( $query_string )
153
-		$success_page .= $query_string;
155
+	if ( $query_string ) {
156
+			$success_page .= $query_string;
157
+	}
154 158
 
155 159
 	return apply_filters( 'wpinv_success_page_url', $success_page );
156 160
 }
@@ -159,8 +163,9 @@  discard block
 block discarded – undo
159 163
 	$uri = wpinv_get_option( 'failure_page', '' );
160 164
 	$uri = ! empty( $uri ) ? trailingslashit( get_permalink( $uri ) ) : home_url();
161 165
 
162
-	if ( $extras )
163
-		$uri .= $extras;
166
+	if ( $extras ) {
167
+			$uri .= $extras;
168
+	}
164 169
 
165 170
 	return apply_filters( 'wpinv_get_failed_transaction_uri', $uri );
166 171
 }
Please login to merge, or discard this patch.
includes/wpinv-item-functions.php 1 patch
Braces   +3 added lines, -2 removed lines patch added patch discarded remove patch
@@ -283,8 +283,9 @@
 block discarded – undo
283 283
 }
284 284
 
285 285
 function wpinv_remove_item_logs_on_delete( $item_id = 0 ) {
286
-    if ( 'wpi_item' !== get_post_type( $item_id ) )
287
-        return;
286
+    if ( 'wpi_item' !== get_post_type( $item_id ) ) {
287
+            return;
288
+    }
288 289
 
289 290
     global $wpinv_logs;
290 291
     
Please login to merge, or discard this patch.
includes/admin/class-wpinv-subscriptions-list-table.php 1 patch
Braces   +3 added lines, -1 removed lines patch added patch discarded remove patch
@@ -3,7 +3,9 @@
 block discarded – undo
3 3
  * Displays a list of all subscriptions rules
4 4
  */
5 5
 
6
-if ( ! defined( 'ABSPATH' ) ) exit;
6
+if ( ! defined( 'ABSPATH' ) ) {
7
+    exit;
8
+}
7 9
 
8 10
 if ( ! class_exists( 'WP_List_Table' ) ) {
9 11
 	include_once ABSPATH . 'wp-admin/includes/class-wp-list-table.php';
Please login to merge, or discard this patch.