Test Failed
Pull Request — master (#2482)
by Devin
05:37
created
templates/single-give-form/title.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -11,7 +11,7 @@
 block discarded – undo
11 11
  * @since       1.0
12 12
  */
13 13
 
14
-if ( ! defined( 'ABSPATH' ) ) {
14
+if ( ! defined('ABSPATH')) {
15 15
 	exit; // Exit if accessed directly.
16 16
 } ?>
17 17
 <h1 itemprop="name" class="give-form-title entry-title"><?php the_title(); ?></h1>
Please login to merge, or discard this patch.
templates/payment-processing.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -5,11 +5,11 @@
 block discarded – undo
5 5
 ?>
6 6
 <div id="give-payment-processing">
7 7
 	<?php
8
-	Give()->notices->print_frontend_notice( sprintf(
8
+	Give()->notices->print_frontend_notice(sprintf(
9 9
 	/* translators: %s: success page URL */
10
-		__( 'Your donation is processing. This page will reload automatically in 8 seconds. If it does not, click <a href="%s">here</a>.', 'give' ),
10
+		__('Your donation is processing. This page will reload automatically in 8 seconds. If it does not, click <a href="%s">here</a>.', 'give'),
11 11
 		give_get_success_page_uri()
12
-	), true, 'success' );
12
+	), true, 'success');
13 13
 	?>
14 14
 	<span class="give-loading-animation"></span>
15 15
 	<script type="text/javascript">setTimeout(function () {
Please login to merge, or discard this patch.
templates/emails/header.php 2 patches
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -6,13 +6,13 @@
 block discarded – undo
6 6
  * @version     1.0
7 7
  */
8 8
 
9
-if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly.
9
+if ( ! defined('ABSPATH')) exit; // Exit if accessed directly.
10 10
 // This is the footer used if no others are available
11 11
 ?>
12 12
 <!DOCTYPE html>
13 13
 <html>
14 14
 	<head>
15 15
 		<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
16
-		<title><?php echo get_bloginfo( 'name' ); ?></title>
16
+		<title><?php echo get_bloginfo('name'); ?></title>
17 17
 	</head>
18 18
 	<body>
19 19
\ No newline at end of file
Please login to merge, or discard this patch.
Braces   +4 added lines, -1 removed lines patch added patch discarded remove patch
@@ -6,7 +6,10 @@
 block discarded – undo
6 6
  * @version     1.0
7 7
  */
8 8
 
9
-if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly.
9
+if ( ! defined( 'ABSPATH' ) ) {
10
+	exit;
11
+}
12
+// Exit if accessed directly.
10 13
 // This is the footer used if no others are available
11 14
 ?>
12 15
 <!DOCTYPE html>
Please login to merge, or discard this patch.
templates/emails/footer-default.php 2 patches
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -6,7 +6,7 @@  discard block
 block discarded – undo
6 6
  * @version     1.0
7 7
  */
8 8
 
9
-if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly.
9
+if ( ! defined('ABSPATH')) exit; // Exit if accessed directly.
10 10
 
11 11
 
12 12
 // For gmail compatibility, including CSS styles in head/body are stripped out therefore styles need to be inline. These variables contain rules which are added to the template inline.
@@ -44,7 +44,7 @@  discard block
 block discarded – undo
44 44
                                                 <table border="0" cellpadding="10" cellspacing="0" width="100%">
45 45
                                                     <tr>
46 46
                                                         <td colspan="2" valign="middle" id="credit" style="<?php echo $credit; ?>">
47
-                                                           <?php echo wpautop( wp_kses_post( wptexturize( apply_filters( 'give_email_footer_text', '<a href="' . esc_url( home_url() ) . '">' . get_bloginfo( 'name' ) . '</a>' ) ) ) ); ?>
47
+                                                           <?php echo wpautop(wp_kses_post(wptexturize(apply_filters('give_email_footer_text', '<a href="'.esc_url(home_url()).'">'.get_bloginfo('name').'</a>')))); ?>
48 48
                                                         </td>
49 49
                                                     </tr>
50 50
                                                 </table>
Please login to merge, or discard this patch.
Braces   +4 added lines, -1 removed lines patch added patch discarded remove patch
@@ -6,7 +6,10 @@
 block discarded – undo
6 6
  * @version     1.0
7 7
  */
8 8
 
9
-if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly.
9
+if ( ! defined( 'ABSPATH' ) ) {
10
+	exit;
11
+}
12
+// Exit if accessed directly.
10 13
 
11 14
 
12 15
 // For gmail compatibility, including CSS styles in head/body are stripped out therefore styles need to be inline. These variables contain rules which are added to the template inline.
Please login to merge, or discard this patch.
templates/emails/body-default.php 2 patches
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -6,7 +6,7 @@
 block discarded – undo
6 6
  * @version     1.0
7 7
  */
8 8
 
9
-if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly.
9
+if ( ! defined('ABSPATH')) exit; // Exit if accessed directly.
10 10
 
11 11
 // {email} is replaced by the content entered in Donations > Settings > Emails
12 12
 
Please login to merge, or discard this patch.
Braces   +4 added lines, -1 removed lines patch added patch discarded remove patch
@@ -6,7 +6,10 @@
 block discarded – undo
6 6
  * @version     1.0
7 7
  */
8 8
 
9
-if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly.
9
+if ( ! defined( 'ABSPATH' ) ) {
10
+	exit;
11
+}
12
+// Exit if accessed directly.
10 13
 
11 14
 // {email} is replaced by the content entered in Donations > Settings > Emails
12 15
 
Please login to merge, or discard this patch.
templates/emails/footer.php 2 patches
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -6,7 +6,7 @@
 block discarded – undo
6 6
  * @version     1.0
7 7
  */
8 8
 
9
-if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly.
9
+if ( ! defined('ABSPATH')) exit; // Exit if accessed directly.
10 10
 
11 11
 // This is the footer used if no others are available
12 12
 
Please login to merge, or discard this patch.
Braces   +4 added lines, -1 removed lines patch added patch discarded remove patch
@@ -6,7 +6,10 @@
 block discarded – undo
6 6
  * @version     1.0
7 7
  */
8 8
 
9
-if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly.
9
+if ( ! defined( 'ABSPATH' ) ) {
10
+	exit;
11
+}
12
+// Exit if accessed directly.
10 13
 
11 14
 // This is the footer used if no others are available
12 15
 
Please login to merge, or discard this patch.
templates/emails/header-default.php 1 patch
Spacing   +9 added lines, -9 removed lines patch added patch discarded remove patch
@@ -6,16 +6,16 @@  discard block
 block discarded – undo
6 6
  * @version     1.0
7 7
  */
8 8
 
9
-if ( ! defined( 'ABSPATH' ) ) {
9
+if ( ! defined('ABSPATH')) {
10 10
 	exit;
11 11
 } // Exit if accessed directly.
12 12
 
13 13
 // For gmail compatibility, including CSS styles in head/body are stripped out therefore styles need to be inline. These variables contain rules which are added to the template inline. !important; is a gmail hack to prevent styles being stripped if it doesn't like something.
14
-$body               = "
14
+$body = "
15 15
 	background-color: #f6f6f6;
16 16
 	font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;
17 17
 ";
18
-$wrapper            = "
18
+$wrapper = "
19 19
 	width:100%;
20 20
 	-webkit-text-size-adjust:none !important;
21 21
 	margin:0;
@@ -42,7 +42,7 @@  discard block
 block discarded – undo
42 42
 	text-align: center;
43 43
 	vertical-align:middle;
44 44
 ";
45
-$body_content       = "
45
+$body_content = "
46 46
 	border-radius:3px !important;
47 47
 	font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;
48 48
 ";
@@ -53,7 +53,7 @@  discard block
 block discarded – undo
53 53
 	line-height:150%;
54 54
 	text-align:left;
55 55
 ";
56
-$header_content_h1  = "
56
+$header_content_h1 = "
57 57
 	color: #000000;
58 58
 	margin:0;
59 59
 	padding: 28px 24px;
@@ -63,13 +63,13 @@  discard block
 block discarded – undo
63 63
 	font-weight: 500;
64 64
 	line-height: 1.2;
65 65
 ";
66
-$header_img         = give_get_option( 'email_logo', '' );
66
+$header_img = give_get_option('email_logo', '');
67 67
 ?>
68 68
 <!DOCTYPE html>
69 69
 <html>
70 70
 <head>
71 71
 	<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
72
-	<title><?php echo get_bloginfo( 'name' ); ?></title>
72
+	<title><?php echo get_bloginfo('name'); ?></title>
73 73
 </head>
74 74
 <body leftmargin="0" marginwidth="0" topmargin="0" marginheight="0" offset="0" style="<?php echo $body; ?>">
75 75
 <div style="<?php echo $wrapper; ?>">
@@ -77,9 +77,9 @@  discard block
 block discarded – undo
77 77
 		<tr>
78 78
 			<td align="center" valign="top">
79 79
 				<?php
80
-				if ( ! empty( $header_img ) ) : ?>
80
+				if ( ! empty($header_img)) : ?>
81 81
 					<div id="template_header_image">
82
-						<?php echo '<p style="margin-top:0;"><img style="' . $template_image . '" src="' . esc_url( $header_img ) . '" alt="' . get_bloginfo( 'name' ) . '" /></p>'; ?>
82
+						<?php echo '<p style="margin-top:0;"><img style="'.$template_image.'" src="'.esc_url($header_img).'" alt="'.get_bloginfo('name').'" /></p>'; ?>
83 83
 					</div>
84 84
 				<?php endif; ?>
85 85
 				<table border="0" cellpadding="0" cellspacing="0" width="600" id="template_container" style="<?php echo $template_container; ?>">
Please login to merge, or discard this patch.
templates/emails/body.php 2 patches
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -6,7 +6,7 @@
 block discarded – undo
6 6
  * @version     1.0
7 7
  */
8 8
 
9
-if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly.
9
+if ( ! defined('ABSPATH')) exit; // Exit if accessed directly.
10 10
 
11 11
 // {email} is replaced by the content entered in Donations > Settings > Emails
12 12
 
Please login to merge, or discard this patch.
Braces   +4 added lines, -1 removed lines patch added patch discarded remove patch
@@ -6,7 +6,10 @@
 block discarded – undo
6 6
  * @version     1.0
7 7
  */
8 8
 
9
-if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly.
9
+if ( ! defined( 'ABSPATH' ) ) {
10
+	exit;
11
+}
12
+// Exit if accessed directly.
10 13
 
11 14
 // {email} is replaced by the content entered in Donations > Settings > Emails
12 15
 
Please login to merge, or discard this patch.
includes/plugin-compatibility.php 2 patches
Indentation   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -39,8 +39,8 @@
 block discarded – undo
39 39
 	}
40 40
 
41 41
 	if ( ( is_plugin_active( 'wordpress-seo/wp-seo.php' )
42
-	       || is_plugin_active( 'wordpress-seo-premium/wp-seo-premium.php' ) )
43
-	     && class_exists( 'WPSEO_Sitemaps_Cache' )
42
+		   || is_plugin_active( 'wordpress-seo-premium/wp-seo-premium.php' ) )
43
+		 && class_exists( 'WPSEO_Sitemaps_Cache' )
44 44
 	) {
45 45
 
46 46
 		$forms_singular_option = give_get_option( 'forms_singular' );
Please login to merge, or discard this patch.
Spacing   +13 added lines, -13 removed lines patch added patch discarded remove patch
@@ -19,10 +19,10 @@  discard block
 block discarded – undo
19 19
  * @return void
20 20
  */
21 21
 function give_disable_mandrill_nl2br() {
22
-	add_filter( 'mandrill_nl2br', '__return_false' );
22
+	add_filter('mandrill_nl2br', '__return_false');
23 23
 }
24 24
 
25
-add_action( 'give_email_send_before', 'give_disable_mandrill_nl2br' );
25
+add_action('give_email_send_before', 'give_disable_mandrill_nl2br');
26 26
 
27 27
 
28 28
 /**
@@ -34,30 +34,30 @@  discard block
 block discarded – undo
34 34
  */
35 35
 function give_clear_seo_sitemap_cache_on_settings_change() {
36 36
 	// Load required file if the fn 'is_plugin_active' doesn't exists.
37
-	if ( ! function_exists( 'is_plugin_active' ) ) {
38
-		require_once ABSPATH . 'wp-admin/includes/plugin.php';
37
+	if ( ! function_exists('is_plugin_active')) {
38
+		require_once ABSPATH.'wp-admin/includes/plugin.php';
39 39
 	}
40 40
 
41
-	if ( ( is_plugin_active( 'wordpress-seo/wp-seo.php' )
42
-	       || is_plugin_active( 'wordpress-seo-premium/wp-seo-premium.php' ) )
43
-	     && class_exists( 'WPSEO_Sitemaps_Cache' )
41
+	if ((is_plugin_active('wordpress-seo/wp-seo.php')
42
+	       || is_plugin_active('wordpress-seo-premium/wp-seo-premium.php'))
43
+	     && class_exists('WPSEO_Sitemaps_Cache')
44 44
 	) {
45 45
 
46
-		$forms_singular_option = give_get_option( 'forms_singular' );
47
-		$forms_archive_option  = give_get_option( 'forms_singular' );
46
+		$forms_singular_option = give_get_option('forms_singular');
47
+		$forms_archive_option  = give_get_option('forms_singular');
48 48
 
49 49
 		// If there is change detected for Single Form View and Form Archives options then proceed.
50 50
 		if (
51
-			( isset( $_POST['forms_singular'] ) && $_POST['forms_singular'] !== $forms_singular_option ) ||
52
-			( isset( $_POST['forms_archives'] ) && $_POST['forms_archives'] !== $forms_archive_option )
51
+			(isset($_POST['forms_singular']) && $_POST['forms_singular'] !== $forms_singular_option) ||
52
+			(isset($_POST['forms_archives']) && $_POST['forms_archives'] !== $forms_archive_option)
53 53
 		) {
54 54
 			// If Yoast SEO or Yoast SEO Premium plugin exists, then update seo sitemap cache.
55 55
 			$yoast_sitemaps_cache = new WPSEO_Sitemaps_Cache();
56
-			if ( method_exists( $yoast_sitemaps_cache, 'clear' ) ) {
56
+			if (method_exists($yoast_sitemaps_cache, 'clear')) {
57 57
 				WPSEO_Sitemaps_Cache::clear();
58 58
 			}
59 59
 		}
60 60
 	}
61 61
 }
62 62
 
63
-add_action( 'give-settings_save_display', 'give_clear_seo_sitemap_cache_on_settings_change' );
63
+add_action('give-settings_save_display', 'give_clear_seo_sitemap_cache_on_settings_change');
Please login to merge, or discard this patch.