Test Failed
Push — master ( 5bee01...7846bd )
by Devin
04:17
created
includes/admin/settings/class-settings-advanced.php 1 patch
Spacing   +30 added lines, -30 removed lines patch added patch discarded remove patch
@@ -9,11 +9,11 @@  discard block
 block discarded – undo
9 9
  * @since       1.8
10 10
  */
11 11
 
12
-if ( ! defined( 'ABSPATH' ) ) {
12
+if ( ! defined('ABSPATH')) {
13 13
 	exit; // Exit if accessed directly
14 14
 }
15 15
 
16
-if ( ! class_exists( 'Give_Settings_Advanced' ) ) :
16
+if ( ! class_exists('Give_Settings_Advanced')) :
17 17
 
18 18
 	/**
19 19
 	 * Give_Settings_Advanced.
@@ -27,7 +27,7 @@  discard block
 block discarded – undo
27 27
 		 */
28 28
 		public function __construct() {
29 29
 			$this->id    = 'advanced';
30
-			$this->label = __( 'Advanced', 'give' );
30
+			$this->label = __('Advanced', 'give');
31 31
 
32 32
 			$this->default_tab = 'advanced-options';
33 33
 
@@ -45,7 +45,7 @@  discard block
 block discarded – undo
45 45
 
46 46
 			$current_section = give_get_current_setting_section();
47 47
 
48
-			switch ( $current_section ) {
48
+			switch ($current_section) {
49 49
 				case 'advanced-options':
50 50
 					$settings = array(
51 51
 						array(
@@ -53,19 +53,19 @@  discard block
 block discarded – undo
53 53
 							'type' => 'title',
54 54
 						),
55 55
 						array(
56
-							'name'    => __( 'Remove Data on Uninstall', 'give' ),
57
-							'desc'    => __( 'When the plugin is deleted, completely remove all Give data. This includes all Give settings, forms, form meta, donor, donor data, donations. Everything.', 'give' ),
56
+							'name'    => __('Remove Data on Uninstall', 'give'),
57
+							'desc'    => __('When the plugin is deleted, completely remove all Give data. This includes all Give settings, forms, form meta, donor, donor data, donations. Everything.', 'give'),
58 58
 							'id'      => 'uninstall_on_delete',
59 59
 							'type'    => 'radio_inline',
60 60
 							'default' => 'disabled',
61 61
 							'options' => array(
62
-								'enabled'  => __( 'Yes, Remove all data', 'give' ),
63
-								'disabled' => __( 'No, keep my Give settings and donation data', 'give' ),
62
+								'enabled'  => __('Yes, Remove all data', 'give'),
63
+								'disabled' => __('No, keep my Give settings and donation data', 'give'),
64 64
 							),
65 65
 						),
66 66
 						array(
67
-							'name'    => __( 'Default User Role', 'give' ),
68
-							'desc'    => __( 'Assign default user roles for donors when donors opt to register as a WP User.', 'give' ),
67
+							'name'    => __('Default User Role', 'give'),
68
+							'desc'    => __('Assign default user roles for donors when donors opt to register as a WP User.', 'give'),
69 69
 							'id'      => 'donor_default_user_role',
70 70
 							'type'    => 'select',
71 71
 							'default' => 'give_donor',
@@ -73,44 +73,44 @@  discard block
 block discarded – undo
73 73
 						),
74 74
 						array(
75 75
 							/* translators: %s: the_content */
76
-							'name'    => sprintf( __( '%s filter', 'give' ), '<code>the_content</code>' ),
76
+							'name'    => sprintf(__('%s filter', 'give'), '<code>the_content</code>'),
77 77
 							/* translators: 1: https://codex.wordpress.org/Plugin_API/Filter_Reference/the_content 2: the_content */
78
-							'desc'    => sprintf( __( 'If you are seeing extra social buttons, related posts, or other unwanted elements appearing within your forms then you can disable WordPress\' content filter. <a href="%1$s" target="_blank">Learn more</a> about %2$s filter.', 'give' ), esc_url( 'https://codex.wordpress.org/Plugin_API/Filter_Reference/the_content' ), '<code>the_content</code>' ),
78
+							'desc'    => sprintf(__('If you are seeing extra social buttons, related posts, or other unwanted elements appearing within your forms then you can disable WordPress\' content filter. <a href="%1$s" target="_blank">Learn more</a> about %2$s filter.', 'give'), esc_url('https://codex.wordpress.org/Plugin_API/Filter_Reference/the_content'), '<code>the_content</code>'),
79 79
 							'id'      => 'the_content_filter',
80 80
 							'default' => 'enabled',
81 81
 							'type'    => 'radio_inline',
82 82
 							'options' => array(
83
-								'enabled'  => __( 'Enabled', 'give' ),
84
-								'disabled' => __( 'Disabled', 'give' ),
83
+								'enabled'  => __('Enabled', 'give'),
84
+								'disabled' => __('Disabled', 'give'),
85 85
 							),
86 86
 						),
87 87
 						array(
88
-							'name'    => __( 'Script Loading Location', 'give' ),
89
-							'desc'    => __( 'This allows you to load your Give scripts either in the <code>&lt;head&gt;</code> or footer of your website.', 'give' ),
88
+							'name'    => __('Script Loading Location', 'give'),
89
+							'desc'    => __('This allows you to load your Give scripts either in the <code>&lt;head&gt;</code> or footer of your website.', 'give'),
90 90
 							'id'      => 'scripts_footer',
91 91
 							'type'    => 'radio_inline',
92 92
 							'default' => 'disabled',
93 93
 							'options' => array(
94
-								'enabled'  => __( 'Footer', 'give' ),
95
-								'disabled' => __( 'Head', 'give' ),
94
+								'enabled'  => __('Footer', 'give'),
95
+								'disabled' => __('Head', 'give'),
96 96
 							),
97 97
 						),
98 98
 						array(
99
-							'name'    => __( 'Akismet SPAM Protection', 'give' ),
100
-							'desc'    => __( 'Add a layer of SPAM protection to your donation submissions with Akismet. When enabled, donation submissions will be first sent to Akismet\'s API if you have the plugin activated and configured.', 'give' ),
99
+							'name'    => __('Akismet SPAM Protection', 'give'),
100
+							'desc'    => __('Add a layer of SPAM protection to your donation submissions with Akismet. When enabled, donation submissions will be first sent to Akismet\'s API if you have the plugin activated and configured.', 'give'),
101 101
 							'id'      => 'akismet_spam_protection',
102 102
 							'type'    => 'radio_inline',
103
-							'default' => ( give_check_akismet_key() ) ? 'enabled' : 'disabled',
103
+							'default' => (give_check_akismet_key()) ? 'enabled' : 'disabled',
104 104
 							'options' => array(
105
-								'enabled'  => __( 'Enabled', 'give' ),
106
-								'disabled' => __( 'Disabled', 'give' ),
105
+								'enabled'  => __('Enabled', 'give'),
106
+								'disabled' => __('Disabled', 'give'),
107 107
 							),
108 108
 						),
109 109
 						array(
110
-							'name'  => __( 'Advanced Settings Docs Link', 'give' ),
110
+							'name'  => __('Advanced Settings Docs Link', 'give'),
111 111
 							'id'    => 'advanced_settings_docs_link',
112
-							'url'   => esc_url( 'http://docs.givewp.com/settings-advanced' ),
113
-							'title' => __( 'Advanced Settings', 'give' ),
112
+							'url'   => esc_url('http://docs.givewp.com/settings-advanced'),
113
+							'title' => __('Advanced Settings', 'give'),
114 114
 							'type'  => 'give_docs_link',
115 115
 						),
116 116
 						array(
@@ -126,7 +126,7 @@  discard block
 block discarded – undo
126 126
 			 * Filter the advanced settings.
127 127
 			 * Backward compatibility: Please do not use this filter. This filter is deprecated in 1.8
128 128
 			 */
129
-			$settings = apply_filters( 'give_settings_advanced', $settings );
129
+			$settings = apply_filters('give_settings_advanced', $settings);
130 130
 
131 131
 			/**
132 132
 			 * Filter the settings.
@@ -135,7 +135,7 @@  discard block
 block discarded – undo
135 135
 			 *
136 136
 			 * @param  array $settings
137 137
 			 */
138
-			$settings = apply_filters( 'give_get_settings_' . $this->id, $settings );
138
+			$settings = apply_filters('give_get_settings_'.$this->id, $settings);
139 139
 
140 140
 			// Output.
141 141
 			return $settings;
@@ -149,10 +149,10 @@  discard block
 block discarded – undo
149 149
 		 */
150 150
 		public function get_sections() {
151 151
 			$sections = array(
152
-				'advanced-options' => __( 'Advanced Options', 'give' ),
152
+				'advanced-options' => __('Advanced Options', 'give'),
153 153
 			);
154 154
 
155
-			return apply_filters( 'give_get_sections_' . $this->id, $sections );
155
+			return apply_filters('give_get_sections_'.$this->id, $sections);
156 156
 		}
157 157
 	}
158 158
 
Please login to merge, or discard this patch.