Passed
Push — master ( 8cf7d7...1f8a22 )
by Brian
04:30
created
templates/payment-forms/elements/billing_email.php 1 patch
Spacing   +14 added lines, -14 removed lines patch added patch discarded remove patch
@@ -7,35 +7,35 @@  discard block
 block discarded – undo
7 7
  * @version 1.0.19
8 8
  */
9 9
 
10
-defined( 'ABSPATH' ) || exit;
10
+defined('ABSPATH') || exit;
11 11
 
12 12
 $value = $query_value;
13 13
 $class = '';
14 14
 
15
-if ( ! empty( $form->invoice ) ) {
16
-    $value   = sanitize_email( $form->invoice->get_email() );
17
-} elseif ( is_user_logged_in() ) {
15
+if (!empty($form->invoice)) {
16
+    $value = sanitize_email($form->invoice->get_email());
17
+} elseif (is_user_logged_in()) {
18 18
     $user  = wp_get_current_user();
19
-    $value = sanitize_email( $user->user_email );
19
+    $value = sanitize_email($user->user_email);
20 20
 }
21 21
 
22
-if ( ! empty( $value ) && ! empty( $hide_billing_email ) ) {
22
+if (!empty($value) && !empty($hide_billing_email)) {
23 23
     $class = 'd-none';
24 24
 }
25 25
 
26
-do_action( 'getpaid_before_payment_form_billing_email', $form );
26
+do_action('getpaid_before_payment_form_billing_email', $form);
27 27
 
28
-echo "<span class='" . esc_attr( $class ) . "'>";
28
+echo "<span class='" . esc_attr($class) . "'>";
29 29
 
30 30
 aui()->input(
31 31
     array(
32 32
         'name'             => 'billing_email',
33
-        'id'               => esc_attr( $element_id ),
34
-        'placeholder'      => empty( $placeholder ) ? '' : esc_attr( $placeholder ),
35
-        'required'         => ! empty( $required ),
36
-        'label'            => empty( $label ) ? '' : wp_kses_post( $label ) . '<span class="text-danger"> *</span>',
33
+        'id'               => esc_attr($element_id),
34
+        'placeholder'      => empty($placeholder) ? '' : esc_attr($placeholder),
35
+        'required'         => !empty($required),
36
+        'label'            => empty($label) ? '' : wp_kses_post($label) . '<span class="text-danger"> *</span>',
37 37
         'label_type'       => 'vertical',
38
-        'help_text'        => empty( $description ) ? '' : wp_kses_post( $description ),
38
+        'help_text'        => empty($description) ? '' : wp_kses_post($description),
39 39
         'type'             => 'email',
40 40
         'value'            => $value,
41 41
         'class'            => 'wpinv_billing_email getpaid-refresh-on-change',
@@ -48,4 +48,4 @@  discard block
 block discarded – undo
48 48
 
49 49
 echo '</span>';
50 50
 
51
-do_action( 'getpaid_after_payment_form_billing_email', $form );
51
+do_action('getpaid_after_payment_form_billing_email', $form);
Please login to merge, or discard this patch.