Test Failed
Pull Request — master (#3647)
by Ravinder
10:22
created
includes/admin/shortcodes/shortcode-give-donor-wall.php 1 patch
Spacing   +34 added lines, -34 removed lines patch added patch discarded remove patch
@@ -10,7 +10,7 @@  discard block
 block discarded – undo
10 10
  */
11 11
 
12 12
 // Exit if accessed directly.
13
-if ( ! defined( 'ABSPATH' ) ) {
13
+if ( ! defined('ABSPATH')) {
14 14
 	exit;
15 15
 }
16 16
 
@@ -24,10 +24,10 @@  discard block
 block discarded – undo
24 24
 	 */
25 25
 	public function __construct() {
26 26
 
27
-		$this->shortcode['title'] = esc_html__( 'Donor Wall', 'give' );
28
-		$this->shortcode['label'] = esc_html__( 'Donor Wall', 'give' );
27
+		$this->shortcode['title'] = esc_html__('Donor Wall', 'give');
28
+		$this->shortcode['label'] = esc_html__('Donor Wall', 'give');
29 29
 
30
-		parent::__construct( 'give_donor_wall' );
30
+		parent::__construct('give_donor_wall');
31 31
 	}
32 32
 
33 33
 	/**
@@ -43,90 +43,90 @@  discard block
 block discarded – undo
43 43
 					'post_type' => 'give_forms',
44 44
 				),
45 45
 				'name'        => 'form_id',
46
-				'tooltip'     => esc_attr__( 'Select a Donation Form', 'give' ),
47
-				'placeholder' => '- ' . esc_attr__( 'Select a Donation Form', 'give' ) . ' -',
46
+				'tooltip'     => esc_attr__('Select a Donation Form', 'give'),
47
+				'placeholder' => '- '.esc_attr__('Select a Donation Form', 'give').' -',
48 48
 			),
49 49
 			array(
50 50
 				'type'        => 'textbox',
51 51
 				'name'        => 'donors_per_page',
52
-				'label'       => esc_attr__( 'Donors Per Page', 'give' ),
52
+				'label'       => esc_attr__('Donors Per Page', 'give'),
53 53
 				'placeholder' => '20',
54 54
 			),
55 55
 			array(
56 56
 				'type'        => 'textbox',
57 57
 				'name'        => 'comment_length',
58
-				'label'       => esc_attr__( 'Comment Length', 'give' ),
58
+				'label'       => esc_attr__('Comment Length', 'give'),
59 59
 				'placeholder' => '20',
60 60
 			),
61 61
 			array(
62 62
 				'type'        => 'textbox',
63 63
 				'name'        => 'readmore_text',
64
-				'label'       => esc_attr__( 'Read More Text', 'give' ),
65
-				'placeholder' => esc_html__( 'Read More', 'give' ),
64
+				'label'       => esc_attr__('Read More Text', 'give'),
65
+				'placeholder' => esc_html__('Read More', 'give'),
66 66
 			),
67 67
 			array(
68 68
 				'type'        => 'textbox',
69 69
 				'name'        => 'loadmore_text',
70
-				'label'       => esc_attr__( 'Load More Text', 'give' ),
71
-				'placeholder' => esc_html__( 'Load More', 'give' ),
70
+				'label'       => esc_attr__('Load More Text', 'give'),
71
+				'placeholder' => esc_html__('Load More', 'give'),
72 72
 			),
73 73
 			array(
74 74
 				'type'        => 'listbox',
75 75
 				'name'        => 'columns',
76
-				'label'       => esc_attr__( 'Columns:', 'give' ),
77
-				'tooltip'     => esc_attr__( 'Sets the number of forms per row.', 'give' ),
76
+				'label'       => esc_attr__('Columns:', 'give'),
77
+				'tooltip'     => esc_attr__('Sets the number of forms per row.', 'give'),
78 78
 				'options'     => array(
79
-					'1' => esc_html__( '1', 'give' ),
80
-					'2' => esc_html__( '2', 'give' ),
81
-					'3' => esc_html__( '3', 'give' ),
82
-					'4' => esc_html__( '4', 'give' ),
79
+					'1' => esc_html__('1', 'give'),
80
+					'2' => esc_html__('2', 'give'),
81
+					'3' => esc_html__('3', 'give'),
82
+					'4' => esc_html__('4', 'give'),
83 83
 				),
84
-				'placeholder' => esc_html__( 'Best Fit', 'give' ),
84
+				'placeholder' => esc_html__('Best Fit', 'give'),
85 85
 			),
86 86
 			array(
87 87
 				'type'        => 'listbox',
88 88
 				'name'        => 'show_avatar',
89
-				'label'       => esc_attr__( 'Show Avatar', 'give' ),
89
+				'label'       => esc_attr__('Show Avatar', 'give'),
90 90
 				'options'     => array(
91
-					'false' => esc_html__( 'Hide', 'give' ),
91
+					'false' => esc_html__('Hide', 'give'),
92 92
 				),
93
-				'placeholder' => esc_html__( 'Show', 'give' ),
93
+				'placeholder' => esc_html__('Show', 'give'),
94 94
 			),
95 95
 			array(
96 96
 				'type'        => 'listbox',
97 97
 				'name'        => 'show_name',
98
-				'label'       => esc_attr__( 'Show Name', 'give' ),
98
+				'label'       => esc_attr__('Show Name', 'give'),
99 99
 				'options'     => array(
100
-					'false' => esc_html__( 'Hide', 'give' ),
100
+					'false' => esc_html__('Hide', 'give'),
101 101
 				),
102
-				'placeholder' => esc_html__( 'Show', 'give' ),
102
+				'placeholder' => esc_html__('Show', 'give'),
103 103
 			),
104 104
 			array(
105 105
 				'type'        => 'listbox',
106 106
 				'name'        => 'show_total',
107
-				'label'       => esc_attr__( 'Show Total', 'give' ),
107
+				'label'       => esc_attr__('Show Total', 'give'),
108 108
 				'options'     => array(
109
-					'false' => esc_html__( 'Hide', 'give' ),
109
+					'false' => esc_html__('Hide', 'give'),
110 110
 				),
111
-				'placeholder' => esc_html__( 'Show', 'give' ),
111
+				'placeholder' => esc_html__('Show', 'give'),
112 112
 			),
113 113
 			array(
114 114
 				'type'        => 'listbox',
115 115
 				'name'        => 'show_time',
116
-				'label'       => esc_attr__( 'Show Date', 'give' ),
116
+				'label'       => esc_attr__('Show Date', 'give'),
117 117
 				'options'     => array(
118
-					'false' => esc_html__( 'Hide', 'give' ),
118
+					'false' => esc_html__('Hide', 'give'),
119 119
 				),
120
-				'placeholder' => esc_html__( 'Show', 'give' ),
120
+				'placeholder' => esc_html__('Show', 'give'),
121 121
 			),
122 122
 			array(
123 123
 				'type'        => 'listbox',
124 124
 				'name'        => 'show_comments',
125
-				'label'       => esc_attr__( 'Show Comments', 'give' ),
125
+				'label'       => esc_attr__('Show Comments', 'give'),
126 126
 				'options'     => array(
127
-					'false' => esc_html__( 'Hide', 'give' ),
127
+					'false' => esc_html__('Hide', 'give'),
128 128
 				),
129
-				'placeholder' => esc_html__( 'Show', 'give' ),
129
+				'placeholder' => esc_html__('Show', 'give'),
130 130
 			)
131 131
 		);
132 132
 	}
Please login to merge, or discard this patch.
includes/admin/shortcodes/shortcode-give-donation-grid.php 1 patch
Spacing   +36 added lines, -36 removed lines patch added patch discarded remove patch
@@ -9,7 +9,7 @@  discard block
 block discarded – undo
9 9
  */
10 10
 
11 11
 // Exit if accessed directly.
12
-if ( ! defined( 'ABSPATH' ) ) {
12
+if ( ! defined('ABSPATH')) {
13 13
 	exit;
14 14
 }
15 15
 
@@ -23,10 +23,10 @@  discard block
 block discarded – undo
23 23
 	 */
24 24
 	public function __construct() {
25 25
 
26
-		$this->shortcode['title'] = esc_html__( 'Donation Form Grid', 'give' );
27
-		$this->shortcode['label'] = esc_html__( 'Donation Form Grid', 'give' );
26
+		$this->shortcode['title'] = esc_html__('Donation Form Grid', 'give');
27
+		$this->shortcode['label'] = esc_html__('Donation Form Grid', 'give');
28 28
 
29
-		parent::__construct( 'give_form_grid' );
29
+		parent::__construct('give_form_grid');
30 30
 	}
31 31
 
32 32
 	/**
@@ -39,80 +39,80 @@  discard block
 block discarded – undo
39 39
 		return array(
40 40
 			array(
41 41
 				'type' => 'container',
42
-				'html' => sprintf( '<p class="strong margin-top">%s</p>', esc_html__( 'Optional settings', 'give' ) ),
42
+				'html' => sprintf('<p class="strong margin-top">%s</p>', esc_html__('Optional settings', 'give')),
43 43
 			),
44 44
 			array(
45 45
 				'type'        => 'textbox',
46 46
 				'name'        => 'ids',
47
-				'label'       => esc_attr__( 'Form IDs:', 'give' ),
48
-				'tooltip'     => esc_attr__( 'Enter a comma-separated list of form IDs. If empty, all published forms are displayed.', 'give' ),
49
-				'placeholder' => esc_html__( 'All Forms', 'give' )
47
+				'label'       => esc_attr__('Form IDs:', 'give'),
48
+				'tooltip'     => esc_attr__('Enter a comma-separated list of form IDs. If empty, all published forms are displayed.', 'give'),
49
+				'placeholder' => esc_html__('All Forms', 'give')
50 50
 			),
51 51
 			array(
52 52
 				'type'        => 'textbox',
53 53
 				'name'        => 'exclude',
54
-				'label'       => esc_attr__( 'Excluded Form IDs:', 'give' ),
55
-				'tooltip'     => esc_attr__( 'Enter a comma-separated list of form IDs to exclude those from the grid.', 'give' ),
56
-				'placeholder' => esc_html__( 'Excluded Forms', 'give' )
54
+				'label'       => esc_attr__('Excluded Form IDs:', 'give'),
55
+				'tooltip'     => esc_attr__('Enter a comma-separated list of form IDs to exclude those from the grid.', 'give'),
56
+				'placeholder' => esc_html__('Excluded Forms', 'give')
57 57
 			),
58 58
 			array(
59 59
 				'type'        => 'listbox',
60 60
 				'name'        => 'columns',
61
-				'label'       => esc_attr__( 'Columns:', 'give' ),
62
-				'tooltip'     => esc_attr__( 'Sets the number of forms per row.', 'give' ),
61
+				'label'       => esc_attr__('Columns:', 'give'),
62
+				'tooltip'     => esc_attr__('Sets the number of forms per row.', 'give'),
63 63
 				'options'     => array(
64
-					'1' => esc_html__( '1', 'give' ),
65
-					'2' => esc_html__( '2', 'give' ),
66
-					'3' => esc_html__( '3', 'give' ),
67
-					'4' => esc_html__( '4', 'give' ),
64
+					'1' => esc_html__('1', 'give'),
65
+					'2' => esc_html__('2', 'give'),
66
+					'3' => esc_html__('3', 'give'),
67
+					'4' => esc_html__('4', 'give'),
68 68
 				),
69
-				'placeholder' => esc_html__( 'Best Fit', 'give' )
69
+				'placeholder' => esc_html__('Best Fit', 'give')
70 70
 			),
71 71
 			array(
72 72
 				'type'    => 'listbox',
73 73
 				'name'    => 'show_goal',
74
-				'label'   => esc_attr__( 'Show Goal:', 'give' ),
75
-				'tooltip' => __( 'Do you want to display the goal\'s progress bar?', 'give' ),
74
+				'label'   => esc_attr__('Show Goal:', 'give'),
75
+				'tooltip' => __('Do you want to display the goal\'s progress bar?', 'give'),
76 76
 				'options' => array(
77
-					'true'  => esc_html__( 'Show', 'give' ),
78
-					'false' => esc_html__( 'Hide', 'give' ),
77
+					'true'  => esc_html__('Show', 'give'),
78
+					'false' => esc_html__('Hide', 'give'),
79 79
 				),
80 80
 			),
81 81
 			array(
82 82
 				'type'    => 'listbox',
83 83
 				'name'    => 'show_excerpt',
84
-				'label'   => esc_attr__( 'Show Excerpt:', 'give' ),
85
-				'tooltip' => esc_attr__( 'Do you want to display the excerpt?', 'give' ),
84
+				'label'   => esc_attr__('Show Excerpt:', 'give'),
85
+				'tooltip' => esc_attr__('Do you want to display the excerpt?', 'give'),
86 86
 				'options' => array(
87
-					'true'  => esc_html__( 'Show', 'give' ),
88
-					'false' => esc_html__( 'Hide', 'give' ),
87
+					'true'  => esc_html__('Show', 'give'),
88
+					'false' => esc_html__('Hide', 'give'),
89 89
 				),
90 90
 			),
91 91
 			array(
92 92
 				'type'    => 'listbox',
93 93
 				'name'    => 'show_featured_image',
94
-				'label'   => esc_attr__( 'Show Featured Image:', 'give' ),
95
-				'tooltip' => esc_attr__( 'Do you want to display the featured image?', 'give' ),
94
+				'label'   => esc_attr__('Show Featured Image:', 'give'),
95
+				'tooltip' => esc_attr__('Do you want to display the featured image?', 'give'),
96 96
 				'options' => array(
97
-					'true'  => esc_html__( 'Show', 'give' ),
98
-					'false' => esc_html__( 'Hide', 'give' ),
97
+					'true'  => esc_html__('Show', 'give'),
98
+					'false' => esc_html__('Hide', 'give'),
99 99
 				),
100 100
 			),
101 101
 			array(
102 102
 				'type'    => 'listbox',
103 103
 				'name'    => 'display_style',
104
-				'label'   => esc_attr__( 'Display Style:', 'give' ),
105
-				'tooltip' => esc_attr__( 'Show form as modal window or redirect to a new page?', 'give' ),
104
+				'label'   => esc_attr__('Display Style:', 'give'),
105
+				'tooltip' => esc_attr__('Show form as modal window or redirect to a new page?', 'give'),
106 106
 				'options' => array(
107
-					'redirect'     => esc_html__( 'Redirect', 'give' ),
108
-					'modal_reveal' => esc_html__( 'Modal', 'give' ),
107
+					'redirect'     => esc_html__('Redirect', 'give'),
108
+					'modal_reveal' => esc_html__('Modal', 'give'),
109 109
 				),
110 110
 			),
111 111
 			array(
112 112
 				'type'    => 'textbox',
113 113
 				'name'    => 'forms_per_page',
114
-				'label'   => esc_attr__( 'Forms Per Page:', 'give' ),
115
-				'tooltip' => esc_attr__( 'Sets the number of forms to display per page.', 'give' ),
114
+				'label'   => esc_attr__('Forms Per Page:', 'give'),
115
+				'tooltip' => esc_attr__('Sets the number of forms to display per page.', 'give'),
116 116
 				'value'   => 12,
117 117
 			),
118 118
 		);
Please login to merge, or discard this patch.
includes/class-give-donor-wall-widget.php 1 patch
Spacing   +18 added lines, -18 removed lines patch added patch discarded remove patch
@@ -10,7 +10,7 @@  discard block
 block discarded – undo
10 10
  */
11 11
 
12 12
 // Exit if accessed directly.
13
-if ( ! defined( 'ABSPATH' ) ) {
13
+if ( ! defined('ABSPATH')) {
14 14
 	exit;
15 15
 }
16 16
 
@@ -34,7 +34,7 @@  discard block
 block discarded – undo
34 34
 		// widget settings
35 35
 		$widget_ops = array(
36 36
 			'classname'   => 'give-donors-gravatars',
37
-			'description' => esc_html__( 'Displays gravatars of people who have donated using your your form. Will only show on the single form page.', 'give' ),
37
+			'description' => esc_html__('Displays gravatars of people who have donated using your your form. Will only show on the single form page.', 'give'),
38 38
 		);
39 39
 
40 40
 		// widget control settings
@@ -47,7 +47,7 @@  discard block
 block discarded – undo
47 47
 		// create the widget
48 48
 		parent::__construct(
49 49
 			'give_donors_gravatars_widget',
50
-			esc_html__( 'Give Donors Gravatars', 'give' ),
50
+			esc_html__('Give Donors Gravatars', 'give'),
51 51
 			$widget_ops,
52 52
 			$control_ops
53 53
 		);
@@ -67,29 +67,29 @@  discard block
 block discarded – undo
67 67
 	 *
68 68
 	 * @return void
69 69
 	 */
70
-	public function widget( $args, $instance ) {
70
+	public function widget($args, $instance) {
71 71
 
72 72
 		//@TODO: Don't extract it!!!
73
-		extract( $args );
73
+		extract($args);
74 74
 
75
-		if ( ! is_singular( 'give_forms' ) ) {
75
+		if ( ! is_singular('give_forms')) {
76 76
 			return;
77 77
 		}
78 78
 
79 79
 		// Variables from widget settings
80
-		$title = apply_filters( 'widget_title', $instance['title'] );
80
+		$title = apply_filters('widget_title', $instance['title']);
81 81
 
82 82
 		// Used by themes. Opens the widget
83 83
 		echo $before_widget;
84 84
 
85 85
 		// Display the widget title
86
-		if ( $title ) {
87
-			echo $before_title . $title . $after_title;
86
+		if ($title) {
87
+			echo $before_title.$title.$after_title;
88 88
 		}
89 89
 
90 90
 		$gravatars = new Give_Donor_Wall();
91 91
 
92
-		echo $gravatars->gravatars( get_the_ID(), null ); // remove title
92
+		echo $gravatars->gravatars(get_the_ID(), null); // remove title
93 93
 
94 94
 		// Used by themes. Closes the widget
95 95
 		echo $after_widget;
@@ -109,11 +109,11 @@  discard block
 block discarded – undo
109 109
 	 *
110 110
 	 * @return array Updated settings to save.
111 111
 	 */
112
-	public function update( $new_instance, $old_instance ) {
112
+	public function update($new_instance, $old_instance) {
113 113
 
114 114
 		$instance = $old_instance;
115 115
 
116
-		$instance['title'] = strip_tags( $new_instance['title'] );
116
+		$instance['title'] = strip_tags($new_instance['title']);
117 117
 
118 118
 		return $instance;
119 119
 
@@ -131,19 +131,19 @@  discard block
 block discarded – undo
131 131
 	 *
132 132
 	 * @return void
133 133
 	 */
134
-	public function form( $instance ) {
134
+	public function form($instance) {
135 135
 
136 136
 		// Set up some default widget settings.
137 137
 		$defaults = array(
138 138
 			'title' => '',
139 139
 		);
140 140
 
141
-		$instance = wp_parse_args( (array) $instance, $defaults ); ?>
141
+		$instance = wp_parse_args((array) $instance, $defaults); ?>
142 142
 
143 143
 		<!-- Title -->
144 144
 		<p>
145
-			<label for="<?php echo $this->get_field_id( 'title' ); ?>"><?php esc_html_e( 'Title:', 'give' ) ?></label>
146
-			<input class="widefat" id="<?php echo $this->get_field_id( 'title' ); ?>" name="<?php echo $this->get_field_name( 'title' ); ?>" type="text" value="<?php echo $instance['title']; ?>" />
145
+			<label for="<?php echo $this->get_field_id('title'); ?>"><?php esc_html_e('Title:', 'give') ?></label>
146
+			<input class="widefat" id="<?php echo $this->get_field_id('title'); ?>" name="<?php echo $this->get_field_name('title'); ?>" type="text" value="<?php echo $instance['title']; ?>" />
147 147
 		</p>
148 148
 
149 149
 		<?php
@@ -154,8 +154,8 @@  discard block
 block discarded – undo
154 154
 	 *
155 155
 	 * @return void
156 156
 	 */
157
-	function widget_init(){
158
-		register_widget( $this->self );
157
+	function widget_init() {
158
+		register_widget($this->self);
159 159
 	}
160 160
 
161 161
 }
Please login to merge, or discard this patch.
includes/currency-functions.php 1 patch
Spacing   +223 added lines, -223 removed lines patch added patch discarded remove patch
@@ -20,17 +20,17 @@  discard block
 block discarded – undo
20 20
  *
21 21
  * @return string The currency code
22 22
  */
23
-function give_get_currency( $donation_or_form_id = null, $args = array() ) {
23
+function give_get_currency($donation_or_form_id = null, $args = array()) {
24 24
 
25 25
 	// Get currency from donation
26
-	if ( is_numeric( $donation_or_form_id ) && 'give_payment' === get_post_type( $donation_or_form_id ) ) {
27
-		$currency = give_get_meta( $donation_or_form_id, '_give_payment_currency', true );
26
+	if (is_numeric($donation_or_form_id) && 'give_payment' === get_post_type($donation_or_form_id)) {
27
+		$currency = give_get_meta($donation_or_form_id, '_give_payment_currency', true);
28 28
 
29
-		if ( empty( $currency ) ) {
30
-			$currency = give_get_option( 'currency', 'USD' );
29
+		if (empty($currency)) {
30
+			$currency = give_get_option('currency', 'USD');
31 31
 		}
32 32
 	} else {
33
-		$currency = give_get_option( 'currency', 'USD' );
33
+		$currency = give_get_option('currency', 'USD');
34 34
 	}
35 35
 
36 36
 	/**
@@ -38,7 +38,7 @@  discard block
 block discarded – undo
38 38
 	 *
39 39
 	 * @since 1.0
40 40
 	 */
41
-	return apply_filters( 'give_currency', $currency, $donation_or_form_id, $args );
41
+	return apply_filters('give_currency', $currency, $donation_or_form_id, $args);
42 42
 }
43 43
 
44 44
 /**
@@ -50,9 +50,9 @@  discard block
 block discarded – undo
50 50
  */
51 51
 function give_get_currency_position() {
52 52
 
53
-	$currency_pos = give_get_option( 'currency_position', 'before' );
53
+	$currency_pos = give_get_option('currency_position', 'before');
54 54
 
55
-	return apply_filters( 'give_currency_position', $currency_pos );
55
+	return apply_filters('give_currency_position', $currency_pos);
56 56
 }
57 57
 
58 58
 /**
@@ -65,7 +65,7 @@  discard block
 block discarded – undo
65 65
 function give_get_currencies_list() {
66 66
 	$currencies = array(
67 67
 		'USD' => array(
68
-			'admin_label' => sprintf( __('US Dollars (%1$s)', 'give'), '&#36;'),
68
+			'admin_label' => sprintf(__('US Dollars (%1$s)', 'give'), '&#36;'),
69 69
 			'symbol'      => '&#36;',
70 70
 			'setting'     => array(
71 71
 				'currency_position'   => 'before',
@@ -75,7 +75,7 @@  discard block
 block discarded – undo
75 75
 			),
76 76
 		),
77 77
 		'EUR' => array(
78
-			'admin_label' => sprintf( __('Euros (%1$s)', 'give'), '&euro;'),
78
+			'admin_label' => sprintf(__('Euros (%1$s)', 'give'), '&euro;'),
79 79
 			'symbol'      => '&euro;',
80 80
 			'setting'     => array(
81 81
 				'currency_position'   => 'before',
@@ -85,7 +85,7 @@  discard block
 block discarded – undo
85 85
 			),
86 86
 		),
87 87
 		'GBP' => array(
88
-			'admin_label' => sprintf( __('Pounds Sterling (%1$s)', 'give'), '&pound;'),
88
+			'admin_label' => sprintf(__('Pounds Sterling (%1$s)', 'give'), '&pound;'),
89 89
 			'symbol'      => '&pound;',
90 90
 			'setting'     => array(
91 91
 				'currency_position'   => 'before',
@@ -95,7 +95,7 @@  discard block
 block discarded – undo
95 95
 			),
96 96
 		),
97 97
 		'AUD' => array(
98
-			'admin_label' => sprintf( __('Australian Dollars (%1$s)', 'give'), '&#36;'),
98
+			'admin_label' => sprintf(__('Australian Dollars (%1$s)', 'give'), '&#36;'),
99 99
 			'symbol'      => '&#36;',
100 100
 			'setting'     => array(
101 101
 				'currency_position'   => 'before',
@@ -105,7 +105,7 @@  discard block
 block discarded – undo
105 105
 			),
106 106
 		),
107 107
 		'BRL' => array(
108
-			'admin_label' => sprintf( __('Brazilian Real (%1$s)', 'give'), '&#82;&#36;'),
108
+			'admin_label' => sprintf(__('Brazilian Real (%1$s)', 'give'), '&#82;&#36;'),
109 109
 			'symbol'      => '&#82;&#36;',
110 110
 			'setting'     => array(
111 111
 				'currency_position'   => 'before',
@@ -115,7 +115,7 @@  discard block
 block discarded – undo
115 115
 			),
116 116
 		),
117 117
 		'CAD' => array(
118
-			'admin_label' => sprintf( __('Canadian Dollars (%1$s)', 'give'), '&#36;'),
118
+			'admin_label' => sprintf(__('Canadian Dollars (%1$s)', 'give'), '&#36;'),
119 119
 			'symbol'      => '&#36;',
120 120
 			'setting'     => array(
121 121
 				'currency_position'   => 'before',
@@ -125,7 +125,7 @@  discard block
 block discarded – undo
125 125
 			),
126 126
 		),
127 127
 		'CZK' => array(
128
-			'admin_label' => sprintf( __('Czech Koruna (%1$s)', 'give'), '&#75;&#269;'),
128
+			'admin_label' => sprintf(__('Czech Koruna (%1$s)', 'give'), '&#75;&#269;'),
129 129
 			'symbol'      => '&#75;&#269;',
130 130
 			'setting'     => array(
131 131
 				'currency_position'   => 'after',
@@ -135,7 +135,7 @@  discard block
 block discarded – undo
135 135
 			),
136 136
 		),
137 137
 		'DKK' => array(
138
-			'admin_label' => sprintf( __('Danish Krone (%1$s)', 'give'), '&nbsp;kr.&nbsp;'),
138
+			'admin_label' => sprintf(__('Danish Krone (%1$s)', 'give'), '&nbsp;kr.&nbsp;'),
139 139
 			'symbol'      => '&nbsp;kr.&nbsp;',
140 140
 			'setting'     => array(
141 141
 				'currency_position'   => 'before',
@@ -145,7 +145,7 @@  discard block
 block discarded – undo
145 145
 			),
146 146
 		),
147 147
 		'HKD' => array(
148
-			'admin_label' => sprintf( __('Hong Kong Dollar (%1$s)', 'give'), '&#36;'),
148
+			'admin_label' => sprintf(__('Hong Kong Dollar (%1$s)', 'give'), '&#36;'),
149 149
 			'symbol'      => '&#36;',
150 150
 			'setting'     => array(
151 151
 				'currency_position'   => 'before',
@@ -155,7 +155,7 @@  discard block
 block discarded – undo
155 155
 			),
156 156
 		),
157 157
 		'HUF' => array(
158
-			'admin_label' => sprintf( __('Hungarian Forint (%1$s)', 'give'), '&#70;&#116;'),
158
+			'admin_label' => sprintf(__('Hungarian Forint (%1$s)', 'give'), '&#70;&#116;'),
159 159
 			'symbol'      => '&#70;&#116;',
160 160
 			'setting'     => array(
161 161
 				'currency_position'   => 'after',
@@ -165,7 +165,7 @@  discard block
 block discarded – undo
165 165
 			),
166 166
 		),
167 167
 		'ILS' => array(
168
-			'admin_label' => sprintf( __('Israeli Shekel (%1$s)', 'give'), '&#8362;'),
168
+			'admin_label' => sprintf(__('Israeli Shekel (%1$s)', 'give'), '&#8362;'),
169 169
 			'symbol'      => '&#8362;',
170 170
 			'setting'     => array(
171 171
 				'currency_position'   => 'after',
@@ -175,7 +175,7 @@  discard block
 block discarded – undo
175 175
 			),
176 176
 		),
177 177
 		'JPY' => array(
178
-			'admin_label' => sprintf( __('Japanese Yen (%1$s)', 'give'), '&yen;'),
178
+			'admin_label' => sprintf(__('Japanese Yen (%1$s)', 'give'), '&yen;'),
179 179
 			'symbol'      => '&yen;',
180 180
 			'setting'     => array(
181 181
 				'currency_position'   => 'before',
@@ -185,7 +185,7 @@  discard block
 block discarded – undo
185 185
 			),
186 186
 		),
187 187
 		'MYR' => array(
188
-			'admin_label' => sprintf( __('Malaysian Ringgits (%1$s)', 'give'), '&#82;&#77;'),
188
+			'admin_label' => sprintf(__('Malaysian Ringgits (%1$s)', 'give'), '&#82;&#77;'),
189 189
 			'symbol'      => '&#82;&#77;',
190 190
 			'setting'     => array(
191 191
 				'currency_position'   => 'before',
@@ -195,7 +195,7 @@  discard block
 block discarded – undo
195 195
 			),
196 196
 		),
197 197
 		'MXN' => array(
198
-			'admin_label' => sprintf( __('Mexican Peso (%1$s)', 'give'), '&#36;'),
198
+			'admin_label' => sprintf(__('Mexican Peso (%1$s)', 'give'), '&#36;'),
199 199
 			'symbol'      => '&#36;',
200 200
 			'setting'     => array(
201 201
 				'currency_position'   => 'before',
@@ -205,7 +205,7 @@  discard block
 block discarded – undo
205 205
 			),
206 206
 		),
207 207
 		'MAD' => array(
208
-			'admin_label' => sprintf( __('Moroccan Dirham (%1$s)', 'give'), '&#x2e;&#x62f;&#x2e;&#x645;'),
208
+			'admin_label' => sprintf(__('Moroccan Dirham (%1$s)', 'give'), '&#x2e;&#x62f;&#x2e;&#x645;'),
209 209
 			'symbol'      => '&#x2e;&#x62f;&#x2e;&#x645;',
210 210
 			'setting'     => array(
211 211
 				'currency_position'   => 'before',
@@ -215,7 +215,7 @@  discard block
 block discarded – undo
215 215
 			),
216 216
 		),
217 217
 		'NZD' => array(
218
-			'admin_label' => sprintf( __('New Zealand Dollar (%1$s)', 'give'), '&#36;'),
218
+			'admin_label' => sprintf(__('New Zealand Dollar (%1$s)', 'give'), '&#36;'),
219 219
 			'symbol'      => '&#36;',
220 220
 			'setting'     => array(
221 221
 				'currency_position'   => 'before',
@@ -225,7 +225,7 @@  discard block
 block discarded – undo
225 225
 			),
226 226
 		),
227 227
 		'NOK' => array(
228
-			'admin_label' => sprintf( __('Norwegian Krone (%1$s)', 'give'), '&#107;&#114;.'),
228
+			'admin_label' => sprintf(__('Norwegian Krone (%1$s)', 'give'), '&#107;&#114;.'),
229 229
 			'symbol'      => '&#107;&#114;.',
230 230
 			'setting'     => array(
231 231
 				'currency_position'   => 'before',
@@ -235,7 +235,7 @@  discard block
 block discarded – undo
235 235
 			),
236 236
 		),
237 237
 		'PHP' => array(
238
-			'admin_label' => sprintf( __('Philippine Pesos (%1$s)', 'give'), '&#8369;'),
238
+			'admin_label' => sprintf(__('Philippine Pesos (%1$s)', 'give'), '&#8369;'),
239 239
 			'symbol'      => '&#8369;',
240 240
 			'setting'     => array(
241 241
 				'currency_position'   => 'before',
@@ -245,7 +245,7 @@  discard block
 block discarded – undo
245 245
 			),
246 246
 		),
247 247
 		'PLN' => array(
248
-			'admin_label' => sprintf( __('Polish Zloty (%1$s)', 'give'), '&#122;&#322;'),
248
+			'admin_label' => sprintf(__('Polish Zloty (%1$s)', 'give'), '&#122;&#322;'),
249 249
 			'symbol'      => '&#122;&#322;',
250 250
 			'setting'     => array(
251 251
 				'currency_position'   => 'after',
@@ -255,7 +255,7 @@  discard block
 block discarded – undo
255 255
 			),
256 256
 		),
257 257
 		'SGD' => array(
258
-			'admin_label' => sprintf( __('Singapore Dollar (%1$s)', 'give'), '&#36;'),
258
+			'admin_label' => sprintf(__('Singapore Dollar (%1$s)', 'give'), '&#36;'),
259 259
 			'symbol'      => '&#36;',
260 260
 			'setting'     => array(
261 261
 				'currency_position'   => 'before',
@@ -265,7 +265,7 @@  discard block
 block discarded – undo
265 265
 			),
266 266
 		),
267 267
 		'KRW' => array(
268
-			'admin_label' => sprintf( __('South Korean Won (%1$s)', 'give'), '&#8361;'),
268
+			'admin_label' => sprintf(__('South Korean Won (%1$s)', 'give'), '&#8361;'),
269 269
 			'symbol'      => '&#8361;',
270 270
 			'setting'     => array(
271 271
 				'currency_position'   => 'before',
@@ -275,7 +275,7 @@  discard block
 block discarded – undo
275 275
 			),
276 276
 		),
277 277
 		'ZAR' => array(
278
-			'admin_label' => sprintf( __('South African Rand (%1$s)', 'give'), '&#82;'),
278
+			'admin_label' => sprintf(__('South African Rand (%1$s)', 'give'), '&#82;'),
279 279
 			'symbol'      => '&#82;',
280 280
 			'setting'     => array(
281 281
 				'currency_position'   => 'before',
@@ -285,7 +285,7 @@  discard block
 block discarded – undo
285 285
 			),
286 286
 		),
287 287
 		'SEK' => array(
288
-			'admin_label' => sprintf( __('Swedish Krona (%1$s)', 'give'), '&nbsp;kr.&nbsp;'),
288
+			'admin_label' => sprintf(__('Swedish Krona (%1$s)', 'give'), '&nbsp;kr.&nbsp;'),
289 289
 			'symbol'      => '&nbsp;kr.&nbsp;',
290 290
 			'setting'     => array(
291 291
 				'currency_position'   => 'before',
@@ -295,7 +295,7 @@  discard block
 block discarded – undo
295 295
 			),
296 296
 		),
297 297
 		'CHF' => array(
298
-			'admin_label' => sprintf( __('Swiss Franc (%1$s)', 'give'), '&#70;&#114;'),
298
+			'admin_label' => sprintf(__('Swiss Franc (%1$s)', 'give'), '&#70;&#114;'),
299 299
 			'symbol'      => '&#70;&#114;',
300 300
 			'setting'     => array(
301 301
 				'currency_position'   => 'before',
@@ -305,7 +305,7 @@  discard block
 block discarded – undo
305 305
 			),
306 306
 		),
307 307
 		'TWD' => array(
308
-			'admin_label' => sprintf( __('Taiwan New Dollars (%1$s)', 'give'), '&#78;&#84;&#36;'),
308
+			'admin_label' => sprintf(__('Taiwan New Dollars (%1$s)', 'give'), '&#78;&#84;&#36;'),
309 309
 			'symbol'      => '&#78;&#84;&#36;',
310 310
 			'setting'     => array(
311 311
 				'currency_position'   => 'before',
@@ -315,7 +315,7 @@  discard block
 block discarded – undo
315 315
 			),
316 316
 		),
317 317
 		'THB' => array(
318
-			'admin_label' => sprintf( __('Thai Baht (%1$s)', 'give'), '&#3647;'),
318
+			'admin_label' => sprintf(__('Thai Baht (%1$s)', 'give'), '&#3647;'),
319 319
 			'symbol'      => '&#3647;',
320 320
 			'setting'     => array(
321 321
 				'currency_position'   => 'before',
@@ -325,7 +325,7 @@  discard block
 block discarded – undo
325 325
 			),
326 326
 		),
327 327
 		'INR' => array(
328
-			'admin_label' => sprintf( __('Indian Rupee (%1$s)', 'give'), '&#8377;'),
328
+			'admin_label' => sprintf(__('Indian Rupee (%1$s)', 'give'), '&#8377;'),
329 329
 			'symbol'      => '&#8377;',
330 330
 			'setting'     => array(
331 331
 				'currency_position'   => 'before',
@@ -335,7 +335,7 @@  discard block
 block discarded – undo
335 335
 			),
336 336
 		),
337 337
 		'TRY' => array(
338
-			'admin_label' => sprintf( __('Turkish Lira (%1$s)', 'give'), '&#8378;'),
338
+			'admin_label' => sprintf(__('Turkish Lira (%1$s)', 'give'), '&#8378;'),
339 339
 			'symbol'      => '&#8378;',
340 340
 			'setting'     => array(
341 341
 				'currency_position'   => 'after',
@@ -345,7 +345,7 @@  discard block
 block discarded – undo
345 345
 			),
346 346
 		),
347 347
 		'IRR' => array(
348
-			'admin_label' => sprintf( __('Iranian Rial (%1$s)', 'give'), '&#xfdfc;'),
348
+			'admin_label' => sprintf(__('Iranian Rial (%1$s)', 'give'), '&#xfdfc;'),
349 349
 			'symbol'      => '&#xfdfc;',
350 350
 			'setting'     => array(
351 351
 				'currency_position'   => 'after',
@@ -355,7 +355,7 @@  discard block
 block discarded – undo
355 355
 			),
356 356
 		),
357 357
 		'RUB' => array(
358
-			'admin_label' => sprintf( __('Russian Rubles (%1$s)', 'give'), '&#8381;'),
358
+			'admin_label' => sprintf(__('Russian Rubles (%1$s)', 'give'), '&#8381;'),
359 359
 			'symbol'      => '&#8381;',
360 360
 			'setting'     => array(
361 361
 				'currency_position'   => 'before',
@@ -365,7 +365,7 @@  discard block
 block discarded – undo
365 365
 			),
366 366
 		),
367 367
 		'AED' => array(
368
-			'admin_label' => sprintf( __('United Arab Emirates dirham (%1$s)', 'give'), '&#x62f;.&#x625;'),
368
+			'admin_label' => sprintf(__('United Arab Emirates dirham (%1$s)', 'give'), '&#x62f;.&#x625;'),
369 369
 			'symbol'      => '&#x62f;.&#x625;',
370 370
 			'setting'     => array(
371 371
 				'currency_position'   => 'before',
@@ -375,7 +375,7 @@  discard block
 block discarded – undo
375 375
 			),
376 376
 		),
377 377
 		'AMD' => array(
378
-			'admin_label' => sprintf( __('Armenian dram (%1$s)', 'give'), 'AMD'),
378
+			'admin_label' => sprintf(__('Armenian dram (%1$s)', 'give'), 'AMD'),
379 379
 			'symbol'      => 'AMD', // Add backward compatibility. Using AMD in place of &#1423;
380 380
 			'setting'     => array(
381 381
 				'currency_position'   => 'before',
@@ -385,7 +385,7 @@  discard block
 block discarded – undo
385 385
 			),
386 386
 		),
387 387
 		'ANG' => array(
388
-			'admin_label' => sprintf( __('Netherlands Antillean guilder (%1$s)', 'give'), '&#402;'),
388
+			'admin_label' => sprintf(__('Netherlands Antillean guilder (%1$s)', 'give'), '&#402;'),
389 389
 			'symbol'      => '&#402;',
390 390
 			'setting'     => array(
391 391
 				'currency_position'   => 'before',
@@ -395,7 +395,7 @@  discard block
 block discarded – undo
395 395
 			),
396 396
 		),
397 397
 		'ARS' => array(
398
-			'admin_label' => sprintf( __('Argentine peso (%1$s)', 'give'), '&#36;'),
398
+			'admin_label' => sprintf(__('Argentine peso (%1$s)', 'give'), '&#36;'),
399 399
 			'symbol'      => '&#36;',
400 400
 			'setting'     => array(
401 401
 				'currency_position'   => 'before',
@@ -405,7 +405,7 @@  discard block
 block discarded – undo
405 405
 			),
406 406
 		),
407 407
 		'AWG' => array(
408
-			'admin_label' => sprintf( __( 'Aruban florin (%1$s)', 'give' ), '&#402;' ),
408
+			'admin_label' => sprintf(__('Aruban florin (%1$s)', 'give'), '&#402;'),
409 409
 			'symbol'      => '&#402;',
410 410
 			'setting'     => array(
411 411
 				'currency_position'   => 'before',
@@ -415,7 +415,7 @@  discard block
 block discarded – undo
415 415
 			),
416 416
 		),
417 417
 		'BAM' => array(
418
-			'admin_label' => sprintf( __( 'Bosnia and Herzegovina convertible mark (%1$s)', 'give' ), '&#75;&#77;' ),
418
+			'admin_label' => sprintf(__('Bosnia and Herzegovina convertible mark (%1$s)', 'give'), '&#75;&#77;'),
419 419
 			'symbol'      => '&#75;&#77;',
420 420
 			'setting'     => array(
421 421
 				'currency_position'   => 'before',
@@ -425,7 +425,7 @@  discard block
 block discarded – undo
425 425
 			),
426 426
 		),
427 427
 		'BDT' => array(
428
-			'admin_label' => sprintf( __( 'Bangladeshi taka (%1$s)', 'give' ), '&#2547;' ),
428
+			'admin_label' => sprintf(__('Bangladeshi taka (%1$s)', 'give'), '&#2547;'),
429 429
 			'symbol'      => '&#2547;',
430 430
 			'setting'     => array(
431 431
 				'currency_position'   => 'before',
@@ -435,7 +435,7 @@  discard block
 block discarded – undo
435 435
 			),
436 436
 		),
437 437
 		'BHD' => array(
438
-			'admin_label' => sprintf( __( 'Bahraini dinar (%1$s)', 'give' ), '.&#x62f;.&#x628;' ),
438
+			'admin_label' => sprintf(__('Bahraini dinar (%1$s)', 'give'), '.&#x62f;.&#x628;'),
439 439
 			'symbol'      => '.&#x62f;.&#x628;',
440 440
 			'setting'     => array(
441 441
 				'currency_position'   => 'before',
@@ -445,7 +445,7 @@  discard block
 block discarded – undo
445 445
 			),
446 446
 		),
447 447
 		'BMD' => array(
448
-			'admin_label' => sprintf( __( 'Bermudian dollar (%1$s)', 'give' ), '&#66;&#68;&#36;' ),
448
+			'admin_label' => sprintf(__('Bermudian dollar (%1$s)', 'give'), '&#66;&#68;&#36;'),
449 449
 			'symbol'      => '&#66;&#68;&#36;',
450 450
 			'setting'     => array(
451 451
 				'currency_position'   => 'before',
@@ -455,7 +455,7 @@  discard block
 block discarded – undo
455 455
 			),
456 456
 		),
457 457
 		'BND' => array(
458
-			'admin_label' => sprintf( __( 'Brunei dollar (%1$s)', 'give' ), '&#66;&#36;' ),
458
+			'admin_label' => sprintf(__('Brunei dollar (%1$s)', 'give'), '&#66;&#36;'),
459 459
 			'symbol'      => '&#66;&#36;',
460 460
 			'setting'     => array(
461 461
 				'currency_position'   => 'before',
@@ -465,7 +465,7 @@  discard block
 block discarded – undo
465 465
 			),
466 466
 		),
467 467
 		'BOB' => array(
468
-			'admin_label' => sprintf( __( 'Bolivian boliviano (%1$s)', 'give' ), '&#66;&#115;&#46;' ),
468
+			'admin_label' => sprintf(__('Bolivian boliviano (%1$s)', 'give'), '&#66;&#115;&#46;'),
469 469
 			'symbol'      => '&#66;&#115;&#46;',
470 470
 			'setting'     => array(
471 471
 				'currency_position'   => 'before',
@@ -475,7 +475,7 @@  discard block
 block discarded – undo
475 475
 			),
476 476
 		),
477 477
 		'BSD' => array(
478
-			'admin_label' => sprintf( __( 'Bahamian dollar (%1$s)', 'give' ), '&#66;&#36;' ),
478
+			'admin_label' => sprintf(__('Bahamian dollar (%1$s)', 'give'), '&#66;&#36;'),
479 479
 			'symbol'      => '&#66;&#36;',
480 480
 			'setting'     => array(
481 481
 				'currency_position'   => 'before',
@@ -485,7 +485,7 @@  discard block
 block discarded – undo
485 485
 			),
486 486
 		),
487 487
 		'BWP' => array(
488
-			'admin_label' => sprintf( __( 'Botswana pula (%1$s)', 'give' ), '&#80;' ),
488
+			'admin_label' => sprintf(__('Botswana pula (%1$s)', 'give'), '&#80;'),
489 489
 			'symbol'      => '&#80;',
490 490
 			'setting'     => array(
491 491
 				'currency_position'   => 'before',
@@ -495,7 +495,7 @@  discard block
 block discarded – undo
495 495
 			),
496 496
 		),
497 497
 		'BZD' => array(
498
-			'admin_label' => sprintf( __( 'Belizean dollar (%1$s)', 'give' ), '&#66;&#90;&#36;' ),
498
+			'admin_label' => sprintf(__('Belizean dollar (%1$s)', 'give'), '&#66;&#90;&#36;'),
499 499
 			'symbol'      => '&#66;&#90;&#36;',
500 500
 			'setting'     => array(
501 501
 				'currency_position'   => 'before',
@@ -505,7 +505,7 @@  discard block
 block discarded – undo
505 505
 			),
506 506
 		),
507 507
 		'CLP' => array(
508
-			'admin_label' => sprintf( __( 'Chilean peso (%1$s)', 'give' ), '&#36;' ),
508
+			'admin_label' => sprintf(__('Chilean peso (%1$s)', 'give'), '&#36;'),
509 509
 			'symbol'      => '&#36;',
510 510
 			'setting'     => array(
511 511
 				'currency_position'   => 'before',
@@ -515,7 +515,7 @@  discard block
 block discarded – undo
515 515
 			),
516 516
 		),
517 517
 		'CNY' => array(
518
-			'admin_label' => sprintf( __( 'Chinese yuan (%1$s)', 'give' ), '&yen;' ),
518
+			'admin_label' => sprintf(__('Chinese yuan (%1$s)', 'give'), '&yen;'),
519 519
 			'symbol'      => '&yen;',
520 520
 			'setting'     => array(
521 521
 				'currency_position'   => 'before',
@@ -525,7 +525,7 @@  discard block
 block discarded – undo
525 525
 			),
526 526
 		),
527 527
 		'COP' => array(
528
-			'admin_label' => sprintf( __( 'Colombian peso (%1$s)', 'give' ), '&#36;' ),
528
+			'admin_label' => sprintf(__('Colombian peso (%1$s)', 'give'), '&#36;'),
529 529
 			'symbol'      => '&#36;',
530 530
 			'setting'     => array(
531 531
 				'currency_position'   => 'before',
@@ -535,7 +535,7 @@  discard block
 block discarded – undo
535 535
 			),
536 536
 		),
537 537
 		'CRC' => array(
538
-			'admin_label' => sprintf( __( 'Costa Rican colón (%1$s)', 'give' ), '&#8353;' ),
538
+			'admin_label' => sprintf(__('Costa Rican colón (%1$s)', 'give'), '&#8353;'),
539 539
 			'symbol'      => '&#8353;',
540 540
 			'setting'     => array(
541 541
 				'currency_position'   => 'before',
@@ -545,7 +545,7 @@  discard block
 block discarded – undo
545 545
 			),
546 546
 		),
547 547
 		'CUC' => array(
548
-			'admin_label' => sprintf( __( 'Cuban convertible peso (%1$s)', 'give' ), '&#8369;' ),
548
+			'admin_label' => sprintf(__('Cuban convertible peso (%1$s)', 'give'), '&#8369;'),
549 549
 			'symbol'      => '&#8369;',
550 550
 			'setting'     => array(
551 551
 				'currency_position'   => 'before',
@@ -555,7 +555,7 @@  discard block
 block discarded – undo
555 555
 			),
556 556
 		),
557 557
 		'CUP' => array(
558
-			'admin_label' => sprintf( __( 'Cuban convertible peso (%1$s)', 'give' ), '&#8369;' ),
558
+			'admin_label' => sprintf(__('Cuban convertible peso (%1$s)', 'give'), '&#8369;'),
559 559
 			'symbol'      => '&#8369;',
560 560
 			'setting'     => array(
561 561
 				'currency_position'   => 'before',
@@ -565,7 +565,7 @@  discard block
 block discarded – undo
565 565
 			),
566 566
 		),
567 567
 		'DOP' => array(
568
-			'admin_label' => sprintf( __( 'Dominican peso (%1$s)', 'give' ), '&#82;&#68;&#36;' ),
568
+			'admin_label' => sprintf(__('Dominican peso (%1$s)', 'give'), '&#82;&#68;&#36;'),
569 569
 			'symbol'      => '&#82;&#68;&#36;',
570 570
 			'setting'     => array(
571 571
 				'currency_position'   => 'before',
@@ -575,7 +575,7 @@  discard block
 block discarded – undo
575 575
 			),
576 576
 		),
577 577
 		'EGP' => array(
578
-			'admin_label' => sprintf( __( 'Egyptian pound (%1$s)', 'give' ), '&#69;&pound;' ),
578
+			'admin_label' => sprintf(__('Egyptian pound (%1$s)', 'give'), '&#69;&pound;'),
579 579
 			'symbol'      => '&#69;&pound;',
580 580
 			'setting'     => array(
581 581
 				'currency_position'   => 'before',
@@ -585,7 +585,7 @@  discard block
 block discarded – undo
585 585
 			),
586 586
 		),
587 587
 		'GIP' => array(
588
-			'admin_label' => sprintf( __( 'Gibraltar pound (%1$s)', 'give' ), '&pound;' ),
588
+			'admin_label' => sprintf(__('Gibraltar pound (%1$s)', 'give'), '&pound;'),
589 589
 			'symbol'      => '&pound;',
590 590
 			'setting'     => array(
591 591
 				'currency_position'   => 'before',
@@ -595,7 +595,7 @@  discard block
 block discarded – undo
595 595
 			),
596 596
 		),
597 597
 		'GTQ' => array(
598
-			'admin_label' => sprintf( __( 'Guatemalan quetzal (%1$s)', 'give' ), '&#81;' ),
598
+			'admin_label' => sprintf(__('Guatemalan quetzal (%1$s)', 'give'), '&#81;'),
599 599
 			'symbol'      => '&#81;',
600 600
 			'setting'     => array(
601 601
 				'currency_position'   => 'before',
@@ -605,7 +605,7 @@  discard block
 block discarded – undo
605 605
 			),
606 606
 		),
607 607
 		'HNL' => array(
608
-			'admin_label' => sprintf( __( 'Honduran lempira (%1$s)', 'give' ), '&#76;' ),
608
+			'admin_label' => sprintf(__('Honduran lempira (%1$s)', 'give'), '&#76;'),
609 609
 			'symbol'      => '&#76;',
610 610
 			'setting'     => array(
611 611
 				'currency_position'   => 'before',
@@ -615,7 +615,7 @@  discard block
 block discarded – undo
615 615
 			),
616 616
 		),
617 617
 		'HRK' => array(
618
-			'admin_label' => sprintf( __( 'Croatian kuna (%1$s)', 'give' ), '&#107;&#110;' ),
618
+			'admin_label' => sprintf(__('Croatian kuna (%1$s)', 'give'), '&#107;&#110;'),
619 619
 			'symbol'      => '&#107;&#110;',
620 620
 			'setting'     => array(
621 621
 				'currency_position'   => 'after',
@@ -625,7 +625,7 @@  discard block
 block discarded – undo
625 625
 			),
626 626
 		),
627 627
 		'IDR' => array(
628
-			'admin_label' => sprintf( __( 'Indonesian rupiah (%1$s)', 'give' ), '&#82;&#112;' ),
628
+			'admin_label' => sprintf(__('Indonesian rupiah (%1$s)', 'give'), '&#82;&#112;'),
629 629
 			'symbol'      => '&#82;&#112;',
630 630
 			'setting'     => array(
631 631
 				'currency_position'   => 'before',
@@ -635,7 +635,7 @@  discard block
 block discarded – undo
635 635
 			),
636 636
 		),
637 637
 		'ISK' => array(
638
-			'admin_label' => sprintf( __( 'Icelandic króna (%1$s)', 'give' ), '&#107;&#114;' ),
638
+			'admin_label' => sprintf(__('Icelandic króna (%1$s)', 'give'), '&#107;&#114;'),
639 639
 			'symbol'      => '&#107;&#114;',
640 640
 			'setting'     => array(
641 641
 				'currency_position'   => 'after',
@@ -645,7 +645,7 @@  discard block
 block discarded – undo
645 645
 			),
646 646
 		),
647 647
 		'JMD' => array(
648
-			'admin_label' => sprintf( __( 'Jamaican dollar (%1$s)', 'give' ), '&#106;&#36;' ),
648
+			'admin_label' => sprintf(__('Jamaican dollar (%1$s)', 'give'), '&#106;&#36;'),
649 649
 			'symbol'      => '&#106;&#36;',
650 650
 			'setting'     => array(
651 651
 				'currency_position'   => 'before',
@@ -655,7 +655,7 @@  discard block
 block discarded – undo
655 655
 			),
656 656
 		),
657 657
 		'JOD' => array(
658
-			'admin_label' => sprintf( __( 'Jordanian dinar (%1$s)', 'give' ), '&#x62f;.&#x627;' ),
658
+			'admin_label' => sprintf(__('Jordanian dinar (%1$s)', 'give'), '&#x62f;.&#x627;'),
659 659
 			'symbol'      => '&#x62f;.&#x627;',
660 660
 			'setting'     => array(
661 661
 				'currency_position'   => 'before',
@@ -665,7 +665,7 @@  discard block
 block discarded – undo
665 665
 			),
666 666
 		),
667 667
 		'KES' => array(
668
-			'admin_label' => sprintf( __( 'Kenyan shilling (%1$s)', 'give' ), '&#75;&#83;&#104;' ),
668
+			'admin_label' => sprintf(__('Kenyan shilling (%1$s)', 'give'), '&#75;&#83;&#104;'),
669 669
 			'symbol'      => '&#75;&#83;&#104;',
670 670
 			'setting'     => array(
671 671
 				'currency_position'   => 'before',
@@ -675,7 +675,7 @@  discard block
 block discarded – undo
675 675
 			),
676 676
 		),
677 677
 		'KWD' => array(
678
-			'admin_label' => sprintf( __( 'Kuwaiti dinar (%1$s)', 'give' ), '&#x62f;.&#x643;' ),
678
+			'admin_label' => sprintf(__('Kuwaiti dinar (%1$s)', 'give'), '&#x62f;.&#x643;'),
679 679
 			'symbol'      => '&#x62f;.&#x643;',
680 680
 			'setting'     => array(
681 681
 				'currency_position'   => 'before',
@@ -685,7 +685,7 @@  discard block
 block discarded – undo
685 685
 			),
686 686
 		),
687 687
 		'KYD' => array(
688
-			'admin_label' => sprintf( __( 'Cayman Islands dollar (%1$s)', 'give' ), '&#75;&#89;&#36;' ),
688
+			'admin_label' => sprintf(__('Cayman Islands dollar (%1$s)', 'give'), '&#75;&#89;&#36;'),
689 689
 			'symbol'      => '&#75;&#89;&#36;',
690 690
 			'setting'     => array(
691 691
 				'currency_position'   => 'before',
@@ -695,7 +695,7 @@  discard block
 block discarded – undo
695 695
 			),
696 696
 		),
697 697
 		'MKD' => array(
698
-			'admin_label' => sprintf( __( 'Macedonian denar (%1$s)', 'give' ), '&#x434;&#x435;&#x43d;' ),
698
+			'admin_label' => sprintf(__('Macedonian denar (%1$s)', 'give'), '&#x434;&#x435;&#x43d;'),
699 699
 			'symbol'      => '&#x434;&#x435;&#x43d;',
700 700
 			'setting'     => array(
701 701
 				'currency_position'   => 'before',
@@ -705,7 +705,7 @@  discard block
 block discarded – undo
705 705
 			),
706 706
 		),
707 707
 		'NPR' => array(
708
-			'admin_label' => sprintf( __( 'Nepalese rupee (%1$s)', 'give' ), '&#8360;' ),
708
+			'admin_label' => sprintf(__('Nepalese rupee (%1$s)', 'give'), '&#8360;'),
709 709
 			'symbol'      => '&#8360;',
710 710
 			'setting'     => array(
711 711
 				'currency_position'   => 'before',
@@ -715,7 +715,7 @@  discard block
 block discarded – undo
715 715
 			),
716 716
 		),
717 717
 		'OMR' => array(
718
-			'admin_label' => sprintf( __( 'Omani rial (%1$s)', 'give' ), '&#x631;.&#x639;&#46;' ),
718
+			'admin_label' => sprintf(__('Omani rial (%1$s)', 'give'), '&#x631;.&#x639;&#46;'),
719 719
 			'symbol'      => '&#x631;.&#x639;&#46;',
720 720
 			'setting'     => array(
721 721
 				'currency_position'   => 'before',
@@ -725,7 +725,7 @@  discard block
 block discarded – undo
725 725
 			),
726 726
 		),
727 727
 		'PEN' => array(
728
-			'admin_label' => sprintf( __( 'Peruvian nuevo sol (%1$s)', 'give' ), 'S/.' ),
728
+			'admin_label' => sprintf(__('Peruvian nuevo sol (%1$s)', 'give'), 'S/.'),
729 729
 			'symbol'      => 'S/.',
730 730
 			'setting'     => array(
731 731
 				'currency_position'   => 'before',
@@ -735,7 +735,7 @@  discard block
 block discarded – undo
735 735
 			),
736 736
 		),
737 737
 		'PKR' => array(
738
-			'admin_label' => sprintf( __( 'Pakistani rupee (%1$s)', 'give' ), '&#8360;' ),
738
+			'admin_label' => sprintf(__('Pakistani rupee (%1$s)', 'give'), '&#8360;'),
739 739
 			'symbol'      => '&#8360;',
740 740
 			'setting'     => array(
741 741
 				'currency_position'   => 'before',
@@ -745,7 +745,7 @@  discard block
 block discarded – undo
745 745
 			),
746 746
 		),
747 747
 		'RON' => array(
748
-			'admin_label' => sprintf( __( 'Romanian leu (%1$s)', 'give' ), '&#76;' ),
748
+			'admin_label' => sprintf(__('Romanian leu (%1$s)', 'give'), '&#76;'),
749 749
 			'symbol'      => '&#76;',
750 750
 			'setting'     => array(
751 751
 				'currency_position'   => 'after',
@@ -755,7 +755,7 @@  discard block
 block discarded – undo
755 755
 			),
756 756
 		),
757 757
 		'SAR' => array(
758
-			'admin_label' => sprintf( __( 'Saudi riyal (%1$s)', 'give' ), '&#x631;.&#x633;' ),
758
+			'admin_label' => sprintf(__('Saudi riyal (%1$s)', 'give'), '&#x631;.&#x633;'),
759 759
 			'symbol'      => '&#x631;.&#x633;',
760 760
 			'setting'     => array(
761 761
 				'currency_position'   => 'before',
@@ -765,7 +765,7 @@  discard block
 block discarded – undo
765 765
 			),
766 766
 		),
767 767
 		'SZL' => array(
768
-			'admin_label' => sprintf( __( 'Swazi lilangeni (%1$s)', 'give' ), '&#76;'),
768
+			'admin_label' => sprintf(__('Swazi lilangeni (%1$s)', 'give'), '&#76;'),
769 769
 			'symbol'      => '&#76;',
770 770
 			'setting'     => array(
771 771
 				'currency_position'   => 'before',
@@ -775,7 +775,7 @@  discard block
 block discarded – undo
775 775
 			),
776 776
 		),
777 777
 		'TOP' => array(
778
-			'admin_label' => sprintf( __( 'Tongan paʻanga (%1$s)', 'give' ), '&#84;&#36;'),
778
+			'admin_label' => sprintf(__('Tongan paʻanga (%1$s)', 'give'), '&#84;&#36;'),
779 779
 			'symbol'      => '&#84;&#36;',
780 780
 			'setting'     => array(
781 781
 				'currency_position'   => 'before',
@@ -785,7 +785,7 @@  discard block
 block discarded – undo
785 785
 			),
786 786
 		),
787 787
 		'TZS' => array(
788
-			'admin_label' => sprintf( __( 'Tanzanian shilling (%1$s)', 'give' ), '&#84;&#83;&#104;'),
788
+			'admin_label' => sprintf(__('Tanzanian shilling (%1$s)', 'give'), '&#84;&#83;&#104;'),
789 789
 			'symbol'      => '&#84;&#83;&#104;',
790 790
 			'setting'     => array(
791 791
 				'currency_position'   => 'before',
@@ -795,7 +795,7 @@  discard block
 block discarded – undo
795 795
 			),
796 796
 		),
797 797
 		'UAH' => array(
798
-			'admin_label' => sprintf( __( 'Ukrainian hryvnia (%1$s)', 'give' ), '&#8372;'),
798
+			'admin_label' => sprintf(__('Ukrainian hryvnia (%1$s)', 'give'), '&#8372;'),
799 799
 			'symbol'      => '&#8372;',
800 800
 			'setting'     => array(
801 801
 				'currency_position'   => 'before',
@@ -805,7 +805,7 @@  discard block
 block discarded – undo
805 805
 			),
806 806
 		),
807 807
 		'UYU' => array(
808
-			'admin_label' => sprintf( __( 'Uruguayan peso (%1$s)', 'give' ), '&#36;&#85;'),
808
+			'admin_label' => sprintf(__('Uruguayan peso (%1$s)', 'give'), '&#36;&#85;'),
809 809
 			'symbol'      => '&#36;&#85;',
810 810
 			'setting'     => array(
811 811
 				'currency_position'   => 'before',
@@ -815,7 +815,7 @@  discard block
 block discarded – undo
815 815
 			),
816 816
 		),
817 817
 		'VEF' => array(
818
-			'admin_label' => sprintf( __( 'Venezuelan bolívar (%1$s)', 'give' ), '&#66;&#115;'),
818
+			'admin_label' => sprintf(__('Venezuelan bolívar (%1$s)', 'give'), '&#66;&#115;'),
819 819
 			'symbol'      => '&#66;&#115;',
820 820
 			'setting'     => array(
821 821
 				'currency_position'   => 'before',
@@ -825,7 +825,7 @@  discard block
 block discarded – undo
825 825
 			),
826 826
 		),
827 827
 		'XCD' => array(
828
-			'admin_label' => sprintf( __( 'East Caribbean dollar (%1$s)', 'give' ), '&#69;&#67;&#36;'),
828
+			'admin_label' => sprintf(__('East Caribbean dollar (%1$s)', 'give'), '&#69;&#67;&#36;'),
829 829
 			'symbol'      => '&#69;&#67;&#36;',
830 830
 			'setting'     => array(
831 831
 				'currency_position'   => 'before',
@@ -835,7 +835,7 @@  discard block
 block discarded – undo
835 835
 			),
836 836
 		),
837 837
 		'AFN' => array(
838
-			'admin_label' => sprintf( __('Afghan afghani (%1$s)', 'give'), '&#x60b;'),
838
+			'admin_label' => sprintf(__('Afghan afghani (%1$s)', 'give'), '&#x60b;'),
839 839
 			'symbol'      => '&#x60b;',
840 840
 			'setting'     => array(
841 841
 				'currency_position'   => 'before',
@@ -845,7 +845,7 @@  discard block
 block discarded – undo
845 845
 			),
846 846
 		),
847 847
 		'ALL' => array(
848
-			'admin_label' => sprintf( __('Albanian lek (%1$s)', 'give'), 'L'),
848
+			'admin_label' => sprintf(__('Albanian lek (%1$s)', 'give'), 'L'),
849 849
 			'symbol'      => 'L',
850 850
 			'setting'     => array(
851 851
 				'currency_position'   => 'after',
@@ -855,7 +855,7 @@  discard block
 block discarded – undo
855 855
 			),
856 856
 		),
857 857
 		'AOA' => array(
858
-			'admin_label' => sprintf( __('Angolan kwanza (%1$s)', 'give'), 'Kz'),
858
+			'admin_label' => sprintf(__('Angolan kwanza (%1$s)', 'give'), 'Kz'),
859 859
 			'symbol'      => 'Kz',
860 860
 			'setting'     => array(
861 861
 				'currency_position'   => 'before',
@@ -865,7 +865,7 @@  discard block
 block discarded – undo
865 865
 			),
866 866
 		),
867 867
 		'AZN' => array(
868
-			'admin_label' => sprintf( __('Azerbaijani manat (%1$s)', 'give'), 'AZN'),
868
+			'admin_label' => sprintf(__('Azerbaijani manat (%1$s)', 'give'), 'AZN'),
869 869
 			'symbol'      => 'AZN',
870 870
 			'setting'     => array(
871 871
 				'currency_position'   => 'after',
@@ -875,7 +875,7 @@  discard block
 block discarded – undo
875 875
 			),
876 876
 		),
877 877
 		'BBD' => array(
878
-			'admin_label' => sprintf( __('Barbadian dollar (%1$s)', 'give'), '&#36;'),
878
+			'admin_label' => sprintf(__('Barbadian dollar (%1$s)', 'give'), '&#36;'),
879 879
 			'symbol'      => '&#36;',
880 880
 			'setting'     => array(
881 881
 				'currency_position'   => 'before',
@@ -885,7 +885,7 @@  discard block
 block discarded – undo
885 885
 			),
886 886
 		),
887 887
 		'BGN' => array(
888
-			'admin_label' => sprintf( __('Bulgarian lev (%1$s)', 'give'), '&#1083;&#1074;.'),
888
+			'admin_label' => sprintf(__('Bulgarian lev (%1$s)', 'give'), '&#1083;&#1074;.'),
889 889
 			'symbol'      => '&#1083;&#1074;.',
890 890
 			'setting'     => array(
891 891
 				'currency_position'   => 'after',
@@ -895,7 +895,7 @@  discard block
 block discarded – undo
895 895
 			),
896 896
 		),
897 897
 		'BIF' => array(
898
-			'admin_label' => sprintf( __('Burundian franc (%1$s)', 'give'), 'Fr'),
898
+			'admin_label' => sprintf(__('Burundian franc (%1$s)', 'give'), 'Fr'),
899 899
 			'symbol'      => 'Fr',
900 900
 			'setting'     => array(
901 901
 				'currency_position'   => 'after',
@@ -905,7 +905,7 @@  discard block
 block discarded – undo
905 905
 			),
906 906
 		),
907 907
 		'BTC' => array(
908
-			'admin_label' => sprintf( __('Bitcoin (%1$s)', 'give'), '&#3647;'),
908
+			'admin_label' => sprintf(__('Bitcoin (%1$s)', 'give'), '&#3647;'),
909 909
 			'symbol'      => '&#3647;',
910 910
 			'setting'     => array(
911 911
 				'currency_position'   => 'after',
@@ -915,7 +915,7 @@  discard block
 block discarded – undo
915 915
 			),
916 916
 		),
917 917
 		'BTN' => array(
918
-			'admin_label' => sprintf( __('Bhutanese ngultrum (%1$s)', 'give'), 'Nu.'),
918
+			'admin_label' => sprintf(__('Bhutanese ngultrum (%1$s)', 'give'), 'Nu.'),
919 919
 			'symbol'      => 'Nu.',
920 920
 			'setting'     => array(
921 921
 				'currency_position'   => 'before',
@@ -925,7 +925,7 @@  discard block
 block discarded – undo
925 925
 			),
926 926
 		),
927 927
 		'BYR' => array(
928
-			'admin_label' => sprintf( __('Belarusian ruble (old) (%1$s)', 'give'), 'Br'),
928
+			'admin_label' => sprintf(__('Belarusian ruble (old) (%1$s)', 'give'), 'Br'),
929 929
 			'symbol'      => 'Br',
930 930
 			'setting'     => array(
931 931
 				'currency_position'   => 'after',
@@ -935,7 +935,7 @@  discard block
 block discarded – undo
935 935
 			),
936 936
 		),
937 937
 		'BYN' => array(
938
-			'admin_label' => sprintf( __('Belarusian ruble (%1$s)', 'give'), 'Br'),
938
+			'admin_label' => sprintf(__('Belarusian ruble (%1$s)', 'give'), 'Br'),
939 939
 			'symbol'      => 'Br',
940 940
 			'setting'     => array(
941 941
 				'currency_position'   => 'after',
@@ -945,7 +945,7 @@  discard block
 block discarded – undo
945 945
 			),
946 946
 		),
947 947
 		'CDF' => array(
948
-			'admin_label' => sprintf( __('Congolese franc (%1$s)', 'give'), 'Fr'),
948
+			'admin_label' => sprintf(__('Congolese franc (%1$s)', 'give'), 'Fr'),
949 949
 			'symbol'      => 'Fr',
950 950
 			'setting'     => array(
951 951
 				'currency_position'   => 'after',
@@ -955,7 +955,7 @@  discard block
 block discarded – undo
955 955
 			),
956 956
 		),
957 957
 		'CVE' => array(
958
-			'admin_label' => sprintf( __('Cape Verdean escudo (%1$s)', 'give'), '&#36;'),
958
+			'admin_label' => sprintf(__('Cape Verdean escudo (%1$s)', 'give'), '&#36;'),
959 959
 			'symbol'      => '&#36;',
960 960
 			'setting'     => array(
961 961
 				'currency_position'   => 'before',
@@ -965,7 +965,7 @@  discard block
 block discarded – undo
965 965
 			),
966 966
 		),
967 967
 		'DJF' => array(
968
-			'admin_label' => sprintf( __('Djiboutian franc (%1$s)', 'give'), 'Fr'),
968
+			'admin_label' => sprintf(__('Djiboutian franc (%1$s)', 'give'), 'Fr'),
969 969
 			'symbol'      => 'Fr',
970 970
 			'setting'     => array(
971 971
 				'currency_position'   => 'after',
@@ -975,7 +975,7 @@  discard block
 block discarded – undo
975 975
 			),
976 976
 		),
977 977
 		'DZD' => array(
978
-			'admin_label' => sprintf( __('Algerian dinar (%1$s)', 'give'), '&#x62f;.&#x62c;'),
978
+			'admin_label' => sprintf(__('Algerian dinar (%1$s)', 'give'), '&#x62f;.&#x62c;'),
979 979
 			'symbol'      => '&#x62f;.&#x62c;',
980 980
 			'setting'     => array(
981 981
 				'currency_position'   => 'before',
@@ -985,7 +985,7 @@  discard block
 block discarded – undo
985 985
 			),
986 986
 		),
987 987
 		'ERN' => array(
988
-			'admin_label' => sprintf( __('Eritrean nakfa (%1$s)', 'give'), 'Nfk'),
988
+			'admin_label' => sprintf(__('Eritrean nakfa (%1$s)', 'give'), 'Nfk'),
989 989
 			'symbol'      => 'Nfk',
990 990
 			'setting'     => array(
991 991
 				'currency_position'   => 'after',
@@ -995,7 +995,7 @@  discard block
 block discarded – undo
995 995
 			),
996 996
 		),
997 997
 		'ETB' => array(
998
-			'admin_label' => sprintf( __('Ethiopian birr (%1$s)', 'give'), 'Br'),
998
+			'admin_label' => sprintf(__('Ethiopian birr (%1$s)', 'give'), 'Br'),
999 999
 			'symbol'      => 'Br',
1000 1000
 			'setting'     => array(
1001 1001
 				'currency_position'   => 'before',
@@ -1005,7 +1005,7 @@  discard block
 block discarded – undo
1005 1005
 			),
1006 1006
 		),
1007 1007
 		'FJD' => array(
1008
-			'admin_label' => sprintf( __('Fijian dollar (%1$s)', 'give'), '&#36;'),
1008
+			'admin_label' => sprintf(__('Fijian dollar (%1$s)', 'give'), '&#36;'),
1009 1009
 			'symbol'      => '&#36;',
1010 1010
 			'setting'     => array(
1011 1011
 				'currency_position'   => 'before',
@@ -1015,7 +1015,7 @@  discard block
 block discarded – undo
1015 1015
 			),
1016 1016
 		),
1017 1017
 		'FKP' => array(
1018
-			'admin_label' => sprintf( __('Falkland Islands pound (%1$s)', 'give'), '&pound;'),
1018
+			'admin_label' => sprintf(__('Falkland Islands pound (%1$s)', 'give'), '&pound;'),
1019 1019
 			'symbol'      => '&pound;',
1020 1020
 			'setting'     => array(
1021 1021
 				'currency_position'   => 'before',
@@ -1025,7 +1025,7 @@  discard block
 block discarded – undo
1025 1025
 			),
1026 1026
 		),
1027 1027
 		'GEL' => array(
1028
-			'admin_label' => sprintf( __('Georgian lari (%1$s)', 'give'), '&#x20be;'),
1028
+			'admin_label' => sprintf(__('Georgian lari (%1$s)', 'give'), '&#x20be;'),
1029 1029
 			'symbol'      => '&#x20be;',
1030 1030
 			'setting'     => array(
1031 1031
 				'currency_position'   => 'after',
@@ -1035,7 +1035,7 @@  discard block
 block discarded – undo
1035 1035
 			),
1036 1036
 		),
1037 1037
 		'GGP' => array(
1038
-			'admin_label' => sprintf( __('Guernsey pound (%1$s)', 'give'), '&pound;'),
1038
+			'admin_label' => sprintf(__('Guernsey pound (%1$s)', 'give'), '&pound;'),
1039 1039
 			'symbol'      => '&pound;',
1040 1040
 			'setting'     => array(
1041 1041
 				'currency_position'   => 'before',
@@ -1045,7 +1045,7 @@  discard block
 block discarded – undo
1045 1045
 			),
1046 1046
 		),
1047 1047
 		'GHS' => array(
1048
-			'admin_label' => sprintf( __('Ghana cedi (%1$s)', 'give'), '&#x20b5;'),
1048
+			'admin_label' => sprintf(__('Ghana cedi (%1$s)', 'give'), '&#x20b5;'),
1049 1049
 			'symbol'      => '&#x20b5;',
1050 1050
 			'setting'     => array(
1051 1051
 				'currency_position'   => 'before',
@@ -1055,7 +1055,7 @@  discard block
 block discarded – undo
1055 1055
 			),
1056 1056
 		),
1057 1057
 		'GMD' => array(
1058
-			'admin_label' => sprintf( __('Gambian dalasi (%1$s)', 'give'), 'D'),
1058
+			'admin_label' => sprintf(__('Gambian dalasi (%1$s)', 'give'), 'D'),
1059 1059
 			'symbol'      => 'D',
1060 1060
 			'setting'     => array(
1061 1061
 				'currency_position'   => 'after',
@@ -1065,7 +1065,7 @@  discard block
 block discarded – undo
1065 1065
 			),
1066 1066
 		),
1067 1067
 		'GNF' => array(
1068
-			'admin_label' => sprintf( __('Guinean franc (%1$s)', 'give'), 'Fr'),
1068
+			'admin_label' => sprintf(__('Guinean franc (%1$s)', 'give'), 'Fr'),
1069 1069
 			'symbol'      => 'Fr',
1070 1070
 			'setting'     => array(
1071 1071
 				'currency_position'   => 'after',
@@ -1075,7 +1075,7 @@  discard block
 block discarded – undo
1075 1075
 			),
1076 1076
 		),
1077 1077
 		'GYD' => array(
1078
-			'admin_label' => sprintf( __('Guyanese dollar (%1$s)', 'give'), '&#36;'),
1078
+			'admin_label' => sprintf(__('Guyanese dollar (%1$s)', 'give'), '&#36;'),
1079 1079
 			'symbol'      => '&#36;',
1080 1080
 			'setting'     => array(
1081 1081
 				'currency_position'   => 'before',
@@ -1085,7 +1085,7 @@  discard block
 block discarded – undo
1085 1085
 			),
1086 1086
 		),
1087 1087
 		'HTG' => array(
1088
-			'admin_label' => sprintf( __('Haitian gourde (%1$s)', 'give'), 'G'),
1088
+			'admin_label' => sprintf(__('Haitian gourde (%1$s)', 'give'), 'G'),
1089 1089
 			'symbol'      => 'G',
1090 1090
 			'setting'     => array(
1091 1091
 				'currency_position'   => 'before',
@@ -1095,7 +1095,7 @@  discard block
 block discarded – undo
1095 1095
 			),
1096 1096
 		),
1097 1097
 		'IMP' => array(
1098
-			'admin_label' => sprintf( __('Manx pound (%1$s)', 'give'), '&pound;'),
1098
+			'admin_label' => sprintf(__('Manx pound (%1$s)', 'give'), '&pound;'),
1099 1099
 			'symbol'      => '&pound;',
1100 1100
 			'setting'     => array(
1101 1101
 				'currency_position'   => 'before',
@@ -1105,7 +1105,7 @@  discard block
 block discarded – undo
1105 1105
 			),
1106 1106
 		),
1107 1107
 		'IQD' => array(
1108
-			'admin_label' => sprintf( __('Iraqi dinar (%1$s)', 'give'), '&#x639;.&#x62f;'),
1108
+			'admin_label' => sprintf(__('Iraqi dinar (%1$s)', 'give'), '&#x639;.&#x62f;'),
1109 1109
 			'symbol'      => '&#x639;.&#x62f;',
1110 1110
 			'setting'     => array(
1111 1111
 				'currency_position'   => 'before',
@@ -1115,7 +1115,7 @@  discard block
 block discarded – undo
1115 1115
 			),
1116 1116
 		),
1117 1117
 		'IRT' => array(
1118
-			'admin_label' => sprintf( __('Iranian toman (%1$s)', 'give'), '&#x062A;&#x0648;&#x0645;&#x0627;&#x0646;'),
1118
+			'admin_label' => sprintf(__('Iranian toman (%1$s)', 'give'), '&#x062A;&#x0648;&#x0645;&#x0627;&#x0646;'),
1119 1119
 			'symbol'      => '&#x062A;&#x0648;&#x0645;&#x0627;&#x0646;',
1120 1120
 			'setting'     => array(
1121 1121
 				'currency_position'   => 'after',
@@ -1125,7 +1125,7 @@  discard block
 block discarded – undo
1125 1125
 			),
1126 1126
 		),
1127 1127
 		'JEP' => array(
1128
-			'admin_label' => sprintf( __('Jersey pound (%1$s)', 'give'), '&pound;'),
1128
+			'admin_label' => sprintf(__('Jersey pound (%1$s)', 'give'), '&pound;'),
1129 1129
 			'symbol'      => '&pound;',
1130 1130
 			'setting'     => array(
1131 1131
 				'currency_position'   => 'before',
@@ -1135,7 +1135,7 @@  discard block
 block discarded – undo
1135 1135
 			),
1136 1136
 		),
1137 1137
 		'KGS' => array(
1138
-			'admin_label' => sprintf( __('Kyrgyzstani som (%1$s)', 'give'), '&#x441;&#x43e;&#x43c;'),
1138
+			'admin_label' => sprintf(__('Kyrgyzstani som (%1$s)', 'give'), '&#x441;&#x43e;&#x43c;'),
1139 1139
 			'symbol'      => '&#x441;&#x43e;&#x43c;',
1140 1140
 			'setting'     => array(
1141 1141
 				'currency_position'   => 'after',
@@ -1145,7 +1145,7 @@  discard block
 block discarded – undo
1145 1145
 			),
1146 1146
 		),
1147 1147
 		'KHR' => array(
1148
-			'admin_label' => sprintf( __('Cambodian riel (%1$s)', 'give'), '&#x17db;'),
1148
+			'admin_label' => sprintf(__('Cambodian riel (%1$s)', 'give'), '&#x17db;'),
1149 1149
 			'symbol'      => '&#x17db;',
1150 1150
 			'setting'     => array(
1151 1151
 				'currency_position'   => 'after',
@@ -1155,7 +1155,7 @@  discard block
 block discarded – undo
1155 1155
 			),
1156 1156
 		),
1157 1157
 		'KMF' => array(
1158
-			'admin_label' => sprintf( __('Comorian franc (%1$s)', 'give'), 'Fr'),
1158
+			'admin_label' => sprintf(__('Comorian franc (%1$s)', 'give'), 'Fr'),
1159 1159
 			'symbol'      => 'Fr',
1160 1160
 			'setting'     => array(
1161 1161
 				'currency_position'   => 'after',
@@ -1165,7 +1165,7 @@  discard block
 block discarded – undo
1165 1165
 			),
1166 1166
 		),
1167 1167
 		'KPW' => array(
1168
-			'admin_label' => sprintf( __('North Korean won (%1$s)', 'give'), '&#x20a9;'),
1168
+			'admin_label' => sprintf(__('North Korean won (%1$s)', 'give'), '&#x20a9;'),
1169 1169
 			'symbol'      => '&#x20a9;',
1170 1170
 			'setting'     => array(
1171 1171
 				'currency_position'   => 'before',
@@ -1175,7 +1175,7 @@  discard block
 block discarded – undo
1175 1175
 			),
1176 1176
 		),
1177 1177
 		'KZT' => array(
1178
-			'admin_label' => sprintf( __('Kazakhstani tenge (%1$s)', 'give'), 'KZT'),
1178
+			'admin_label' => sprintf(__('Kazakhstani tenge (%1$s)', 'give'), 'KZT'),
1179 1179
 			'symbol'      => 'KZT',
1180 1180
 			'setting'     => array(
1181 1181
 				'currency_position'   => 'before',
@@ -1185,7 +1185,7 @@  discard block
 block discarded – undo
1185 1185
 			),
1186 1186
 		),
1187 1187
 		'LAK' => array(
1188
-			'admin_label' => sprintf( __('Lao kip (%1$s)', 'give'), '&#8365;'),
1188
+			'admin_label' => sprintf(__('Lao kip (%1$s)', 'give'), '&#8365;'),
1189 1189
 			'symbol'      => '&#8365;',
1190 1190
 			'setting'     => array(
1191 1191
 				'currency_position'   => 'after',
@@ -1195,7 +1195,7 @@  discard block
 block discarded – undo
1195 1195
 			),
1196 1196
 		),
1197 1197
 		'LBP' => array(
1198
-			'admin_label' => sprintf( __('Lebanese pound (%1$s)', 'give'), '&#x644;.&#x644;'),
1198
+			'admin_label' => sprintf(__('Lebanese pound (%1$s)', 'give'), '&#x644;.&#x644;'),
1199 1199
 			'symbol'      => '&#x644;.&#x644;',
1200 1200
 			'setting'     => array(
1201 1201
 				'currency_position'   => 'before',
@@ -1205,7 +1205,7 @@  discard block
 block discarded – undo
1205 1205
 			),
1206 1206
 		),
1207 1207
 		'LKR' => array(
1208
-			'admin_label' => sprintf( __('Sri Lankan rupee (%1$s)', 'give'), '&#xdbb;&#xdd4;'),
1208
+			'admin_label' => sprintf(__('Sri Lankan rupee (%1$s)', 'give'), '&#xdbb;&#xdd4;'),
1209 1209
 			'symbol'      => '&#xdbb;&#xdd4;',
1210 1210
 			'setting'     => array(
1211 1211
 				'currency_position'   => 'before',
@@ -1215,7 +1215,7 @@  discard block
 block discarded – undo
1215 1215
 			),
1216 1216
 		),
1217 1217
 		'LRD' => array(
1218
-			'admin_label' => sprintf( __('Liberian dollar (%1$s)', 'give'), '&#36;'),
1218
+			'admin_label' => sprintf(__('Liberian dollar (%1$s)', 'give'), '&#36;'),
1219 1219
 			'symbol'      => '&#36;',
1220 1220
 			'setting'     => array(
1221 1221
 				'currency_position'   => 'before',
@@ -1225,7 +1225,7 @@  discard block
 block discarded – undo
1225 1225
 			),
1226 1226
 		),
1227 1227
 		'LSL' => array(
1228
-			'admin_label' => sprintf( __('Lesotho loti (%1$s)', 'give'), 'L'),
1228
+			'admin_label' => sprintf(__('Lesotho loti (%1$s)', 'give'), 'L'),
1229 1229
 			'symbol'      => 'L',
1230 1230
 			'setting'     => array(
1231 1231
 				'currency_position'   => 'after',
@@ -1235,7 +1235,7 @@  discard block
 block discarded – undo
1235 1235
 			),
1236 1236
 		),
1237 1237
 		'LYD' => array(
1238
-			'admin_label' => sprintf( __('Libyan dinar (%1$s)', 'give'), '&#x644;.&#x62f;'),
1238
+			'admin_label' => sprintf(__('Libyan dinar (%1$s)', 'give'), '&#x644;.&#x62f;'),
1239 1239
 			'symbol'      => '&#x644;.&#x62f;',
1240 1240
 			'setting'     => array(
1241 1241
 				'currency_position'   => 'before',
@@ -1245,7 +1245,7 @@  discard block
 block discarded – undo
1245 1245
 			),
1246 1246
 		),
1247 1247
 		'MDL' => array(
1248
-			'admin_label' => sprintf( __('Moldovan leu (%1$s)', 'give'), 'MDL'),
1248
+			'admin_label' => sprintf(__('Moldovan leu (%1$s)', 'give'), 'MDL'),
1249 1249
 			'symbol'      => 'MDL',
1250 1250
 			'setting'     => array(
1251 1251
 				'currency_position'   => 'after',
@@ -1255,7 +1255,7 @@  discard block
 block discarded – undo
1255 1255
 			),
1256 1256
 		),
1257 1257
 		'MGA' => array(
1258
-			'admin_label' => sprintf( __('Malagasy ariary (%1$s)', 'give'), 'Ar'),
1258
+			'admin_label' => sprintf(__('Malagasy ariary (%1$s)', 'give'), 'Ar'),
1259 1259
 			'symbol'      => 'Ar',
1260 1260
 			'setting'     => array(
1261 1261
 				'currency_position'   => 'before',
@@ -1265,7 +1265,7 @@  discard block
 block discarded – undo
1265 1265
 			),
1266 1266
 		),
1267 1267
 		'MMK' => array(
1268
-			'admin_label' => sprintf( __('Burmese kyat (%1$s)', 'give'), 'Ks'),
1268
+			'admin_label' => sprintf(__('Burmese kyat (%1$s)', 'give'), 'Ks'),
1269 1269
 			'symbol'      => 'Ks',
1270 1270
 			'setting'     => array(
1271 1271
 				'currency_position'   => 'before',
@@ -1275,7 +1275,7 @@  discard block
 block discarded – undo
1275 1275
 			),
1276 1276
 		),
1277 1277
 		'MNT' => array(
1278
-			'admin_label' => sprintf( __('Mongolian tögrög (%1$s)', 'give'), '&#x20ae;'),
1278
+			'admin_label' => sprintf(__('Mongolian tögrög (%1$s)', 'give'), '&#x20ae;'),
1279 1279
 			'symbol'      => '&#x20ae;',
1280 1280
 			'setting'     => array(
1281 1281
 				'currency_position'   => 'before',
@@ -1285,7 +1285,7 @@  discard block
 block discarded – undo
1285 1285
 			),
1286 1286
 		),
1287 1287
 		'MOP' => array(
1288
-			'admin_label' => sprintf( __('Macanese pataca (%1$s)', 'give'), 'P'),
1288
+			'admin_label' => sprintf(__('Macanese pataca (%1$s)', 'give'), 'P'),
1289 1289
 			'symbol'      => 'P',
1290 1290
 			'setting'     => array(
1291 1291
 				'currency_position'   => 'before',
@@ -1295,7 +1295,7 @@  discard block
 block discarded – undo
1295 1295
 			),
1296 1296
 		),
1297 1297
 		'MRO' => array(
1298
-			'admin_label' => sprintf( __('Mauritanian ouguiya (%1$s)', 'give'), 'UM'),
1298
+			'admin_label' => sprintf(__('Mauritanian ouguiya (%1$s)', 'give'), 'UM'),
1299 1299
 			'symbol'      => 'UM',
1300 1300
 			'setting'     => array(
1301 1301
 				'currency_position'   => 'after',
@@ -1305,7 +1305,7 @@  discard block
 block discarded – undo
1305 1305
 			),
1306 1306
 		),
1307 1307
 		'MUR' => array(
1308
-			'admin_label' => sprintf( __('Mauritian rupee (%1$s)', 'give'), '&#x20a8;'),
1308
+			'admin_label' => sprintf(__('Mauritian rupee (%1$s)', 'give'), '&#x20a8;'),
1309 1309
 			'symbol'      => '&#x20a8;',
1310 1310
 			'setting'     => array(
1311 1311
 				'currency_position'   => 'before',
@@ -1315,7 +1315,7 @@  discard block
 block discarded – undo
1315 1315
 			),
1316 1316
 		),
1317 1317
 		'MVR' => array(
1318
-			'admin_label' => sprintf( __('Maldivian rufiyaa (%1$s)', 'give'), '.&#x783;'),
1318
+			'admin_label' => sprintf(__('Maldivian rufiyaa (%1$s)', 'give'), '.&#x783;'),
1319 1319
 			'symbol'      => '.&#x783;',
1320 1320
 			'setting'     => array(
1321 1321
 				'currency_position'   => 'after',
@@ -1325,7 +1325,7 @@  discard block
 block discarded – undo
1325 1325
 			),
1326 1326
 		),
1327 1327
 		'MWK' => array(
1328
-			'admin_label' => sprintf( __('Malawian kwacha (%1$s)', 'give'), 'MK'),
1328
+			'admin_label' => sprintf(__('Malawian kwacha (%1$s)', 'give'), 'MK'),
1329 1329
 			'symbol'      => 'MK',
1330 1330
 			'setting'     => array(
1331 1331
 				'currency_position'   => 'before',
@@ -1335,7 +1335,7 @@  discard block
 block discarded – undo
1335 1335
 			),
1336 1336
 		),
1337 1337
 		'MZN' => array(
1338
-			'admin_label' => sprintf( __('Mozambican metical (%1$s)', 'give'), 'MT'),
1338
+			'admin_label' => sprintf(__('Mozambican metical (%1$s)', 'give'), 'MT'),
1339 1339
 			'symbol'      => 'MT',
1340 1340
 			'setting'     => array(
1341 1341
 				'currency_position'   => 'before',
@@ -1345,7 +1345,7 @@  discard block
 block discarded – undo
1345 1345
 			),
1346 1346
 		),
1347 1347
 		'NAD' => array(
1348
-			'admin_label' => sprintf( __('Namibian dollar (%1$s)', 'give'), '&#36;'),
1348
+			'admin_label' => sprintf(__('Namibian dollar (%1$s)', 'give'), '&#36;'),
1349 1349
 			'symbol'      => '&#36;',
1350 1350
 			'setting'     => array(
1351 1351
 				'currency_position'   => 'before',
@@ -1355,7 +1355,7 @@  discard block
 block discarded – undo
1355 1355
 			),
1356 1356
 		),
1357 1357
 		'NGN' => array(
1358
-			'admin_label' => sprintf( __('Nigerian naira (%1$s)', 'give'), '&#8358;'),
1358
+			'admin_label' => sprintf(__('Nigerian naira (%1$s)', 'give'), '&#8358;'),
1359 1359
 			'symbol'      => '&#8358;',
1360 1360
 			'setting'     => array(
1361 1361
 				'currency_position'   => 'before',
@@ -1365,7 +1365,7 @@  discard block
 block discarded – undo
1365 1365
 			),
1366 1366
 		),
1367 1367
 		'NIO' => array(
1368
-			'admin_label' => sprintf( __('Nicaraguan córdoba (%1$s)', 'give'), 'C&#36;'),
1368
+			'admin_label' => sprintf(__('Nicaraguan córdoba (%1$s)', 'give'), 'C&#36;'),
1369 1369
 			'symbol'      => 'C&#36;',
1370 1370
 			'setting'     => array(
1371 1371
 				'currency_position'   => 'before',
@@ -1375,7 +1375,7 @@  discard block
 block discarded – undo
1375 1375
 			),
1376 1376
 		),
1377 1377
 		'PAB' => array(
1378
-			'admin_label' => sprintf( __('Panamanian balboa (%1$s)', 'give'), 'B/.'),
1378
+			'admin_label' => sprintf(__('Panamanian balboa (%1$s)', 'give'), 'B/.'),
1379 1379
 			'symbol'      => 'B/.',
1380 1380
 			'setting'     => array(
1381 1381
 				'currency_position'   => 'before',
@@ -1385,7 +1385,7 @@  discard block
 block discarded – undo
1385 1385
 			),
1386 1386
 		),
1387 1387
 		'PGK' => array(
1388
-			'admin_label' => sprintf( __('Papua New Guinean kina (%1$s)', 'give'), 'K'),
1388
+			'admin_label' => sprintf(__('Papua New Guinean kina (%1$s)', 'give'), 'K'),
1389 1389
 			'symbol'      => 'K',
1390 1390
 			'setting'     => array(
1391 1391
 				'currency_position'   => 'before',
@@ -1395,7 +1395,7 @@  discard block
 block discarded – undo
1395 1395
 			),
1396 1396
 		),
1397 1397
 		'PRB' => array(
1398
-			'admin_label' => sprintf( __('Transnistrian ruble (%1$s)', 'give'), '&#x440;.'),
1398
+			'admin_label' => sprintf(__('Transnistrian ruble (%1$s)', 'give'), '&#x440;.'),
1399 1399
 			'symbol'      => '&#x440;.',
1400 1400
 			'setting'     => array(
1401 1401
 				'currency_position'   => 'before',
@@ -1405,7 +1405,7 @@  discard block
 block discarded – undo
1405 1405
 			),
1406 1406
 		),
1407 1407
 		'PYG' => array(
1408
-			'admin_label' => sprintf( __('Paraguayan guaraní (%1$s)', 'give'), '&#8370;'),
1408
+			'admin_label' => sprintf(__('Paraguayan guaraní (%1$s)', 'give'), '&#8370;'),
1409 1409
 			'symbol'      => '&#8370;',
1410 1410
 			'setting'     => array(
1411 1411
 				'currency_position'   => 'before',
@@ -1415,7 +1415,7 @@  discard block
 block discarded – undo
1415 1415
 			),
1416 1416
 		),
1417 1417
 		'QAR' => array(
1418
-			'admin_label' => sprintf( __('Qatari riyal (%1$s)', 'give'), '&#x631;.&#x642;'),
1418
+			'admin_label' => sprintf(__('Qatari riyal (%1$s)', 'give'), '&#x631;.&#x642;'),
1419 1419
 			'symbol'      => '&#x631;.&#x642;',
1420 1420
 			'setting'     => array(
1421 1421
 				'currency_position'   => 'before',
@@ -1425,7 +1425,7 @@  discard block
 block discarded – undo
1425 1425
 			),
1426 1426
 		),
1427 1427
 		'RSD' => array(
1428
-			'admin_label' => sprintf( __('Serbian dinar (%1$s)', 'give'), '&#x434;&#x438;&#x43d;.'),
1428
+			'admin_label' => sprintf(__('Serbian dinar (%1$s)', 'give'), '&#x434;&#x438;&#x43d;.'),
1429 1429
 			'symbol'      => '&#x434;&#x438;&#x43d;.',
1430 1430
 			'setting'     => array(
1431 1431
 				'currency_position'   => 'after',
@@ -1435,7 +1435,7 @@  discard block
 block discarded – undo
1435 1435
 			),
1436 1436
 		),
1437 1437
 		'RWF' => array(
1438
-			'admin_label' => sprintf( __('Rwandan franc (%1$s)', 'give'), 'Fr'),
1438
+			'admin_label' => sprintf(__('Rwandan franc (%1$s)', 'give'), 'Fr'),
1439 1439
 			'symbol'      => 'Fr',
1440 1440
 			'setting'     => array(
1441 1441
 				'currency_position'   => 'before',
@@ -1445,7 +1445,7 @@  discard block
 block discarded – undo
1445 1445
 			),
1446 1446
 		),
1447 1447
 		'SBD' => array(
1448
-			'admin_label' => sprintf( __('Solomon Islands dollar (%1$s)', 'give'), '&#36;'),
1448
+			'admin_label' => sprintf(__('Solomon Islands dollar (%1$s)', 'give'), '&#36;'),
1449 1449
 			'symbol'      => '&#36;',
1450 1450
 			'setting'     => array(
1451 1451
 				'currency_position'   => 'before',
@@ -1455,7 +1455,7 @@  discard block
 block discarded – undo
1455 1455
 			),
1456 1456
 		),
1457 1457
 		'SCR' => array(
1458
-			'admin_label' => sprintf( __('Seychellois rupee (%1$s)', 'give'), '&#x20a8;'),
1458
+			'admin_label' => sprintf(__('Seychellois rupee (%1$s)', 'give'), '&#x20a8;'),
1459 1459
 			'symbol'      => '&#x20a8;',
1460 1460
 			'setting'     => array(
1461 1461
 				'currency_position'   => 'before',
@@ -1465,7 +1465,7 @@  discard block
 block discarded – undo
1465 1465
 			),
1466 1466
 		),
1467 1467
 		'SDG' => array(
1468
-			'admin_label' => sprintf( __('Sudanese pound (%1$s)', 'give'), '&#x62c;.&#x633;.'),
1468
+			'admin_label' => sprintf(__('Sudanese pound (%1$s)', 'give'), '&#x62c;.&#x633;.'),
1469 1469
 			'symbol'      => '&#x62c;.&#x633;.',
1470 1470
 			'setting'     => array(
1471 1471
 				'currency_position'   => 'before',
@@ -1475,7 +1475,7 @@  discard block
 block discarded – undo
1475 1475
 			),
1476 1476
 		),
1477 1477
 		'SHP' => array(
1478
-			'admin_label' => sprintf( __('Saint Helena pound (%1$s)', 'give'), '&pound;'),
1478
+			'admin_label' => sprintf(__('Saint Helena pound (%1$s)', 'give'), '&pound;'),
1479 1479
 			'symbol'      => '&pound;',
1480 1480
 			'setting'     => array(
1481 1481
 				'currency_position'   => 'before',
@@ -1485,7 +1485,7 @@  discard block
 block discarded – undo
1485 1485
 			),
1486 1486
 		),
1487 1487
 		'SLL' => array(
1488
-			'admin_label' => sprintf( __('Sierra Leonean leone (%1$s)', 'give'), 'Le'),
1488
+			'admin_label' => sprintf(__('Sierra Leonean leone (%1$s)', 'give'), 'Le'),
1489 1489
 			'symbol'      => 'Le',
1490 1490
 			'setting'     => array(
1491 1491
 				'currency_position'   => 'before',
@@ -1495,7 +1495,7 @@  discard block
 block discarded – undo
1495 1495
 			),
1496 1496
 		),
1497 1497
 		'SOS' => array(
1498
-			'admin_label' => sprintf( __('Somali shilling (%1$s)', 'give'), 'Sh'),
1498
+			'admin_label' => sprintf(__('Somali shilling (%1$s)', 'give'), 'Sh'),
1499 1499
 			'symbol'      => 'Sh',
1500 1500
 			'setting'     => array(
1501 1501
 				'currency_position'   => 'before',
@@ -1505,7 +1505,7 @@  discard block
 block discarded – undo
1505 1505
 			),
1506 1506
 		),
1507 1507
 		'SRD' => array(
1508
-			'admin_label' => sprintf( __('Surinamese dollar (%1$s)', 'give'), '&#36;'),
1508
+			'admin_label' => sprintf(__('Surinamese dollar (%1$s)', 'give'), '&#36;'),
1509 1509
 			'symbol'      => '&#36;',
1510 1510
 			'setting'     => array(
1511 1511
 				'currency_position'   => 'before',
@@ -1515,7 +1515,7 @@  discard block
 block discarded – undo
1515 1515
 			),
1516 1516
 		),
1517 1517
 		'SSP' => array(
1518
-			'admin_label' => sprintf( __('South Sudanese pound (%1$s)', 'give'), '&pound;'),
1518
+			'admin_label' => sprintf(__('South Sudanese pound (%1$s)', 'give'), '&pound;'),
1519 1519
 			'symbol'      => '&pound;',
1520 1520
 			'setting'     => array(
1521 1521
 				'currency_position'   => 'before',
@@ -1525,7 +1525,7 @@  discard block
 block discarded – undo
1525 1525
 			),
1526 1526
 		),
1527 1527
 		'STD' => array(
1528
-			'admin_label' => sprintf( __('São Tomé and Príncipe dobra (%1$s)', 'give'), 'Db'),
1528
+			'admin_label' => sprintf(__('São Tomé and Príncipe dobra (%1$s)', 'give'), 'Db'),
1529 1529
 			'symbol'      => 'Db',
1530 1530
 			'setting'     => array(
1531 1531
 				'currency_position'   => 'before',
@@ -1535,7 +1535,7 @@  discard block
 block discarded – undo
1535 1535
 			),
1536 1536
 		),
1537 1537
 		'SYP' => array(
1538
-			'admin_label' => sprintf( __('Syrian pound (%1$s)', 'give'), '&#x644;.&#x633;'),
1538
+			'admin_label' => sprintf(__('Syrian pound (%1$s)', 'give'), '&#x644;.&#x633;'),
1539 1539
 			'symbol'      => '&#x644;.&#x633;',
1540 1540
 			'setting'     => array(
1541 1541
 				'currency_position'   => 'before',
@@ -1545,7 +1545,7 @@  discard block
 block discarded – undo
1545 1545
 			),
1546 1546
 		),
1547 1547
 		'TJS' => array(
1548
-			'admin_label' => sprintf( __('Tajikistani somoni (%1$s)', 'give'), '&#x405;&#x41c;'),
1548
+			'admin_label' => sprintf(__('Tajikistani somoni (%1$s)', 'give'), '&#x405;&#x41c;'),
1549 1549
 			'symbol'      => '&#x405;&#x41c;',
1550 1550
 			'setting'     => array(
1551 1551
 				'currency_position'   => 'after',
@@ -1555,7 +1555,7 @@  discard block
 block discarded – undo
1555 1555
 			),
1556 1556
 		),
1557 1557
 		'TMT' => array(
1558
-			'admin_label' => sprintf( __('Turkmenistan manat (%1$s)', 'give'), 'm'),
1558
+			'admin_label' => sprintf(__('Turkmenistan manat (%1$s)', 'give'), 'm'),
1559 1559
 			'symbol'      => 'm',
1560 1560
 			'setting'     => array(
1561 1561
 				'currency_position'   => 'after',
@@ -1565,7 +1565,7 @@  discard block
 block discarded – undo
1565 1565
 			),
1566 1566
 		),
1567 1567
 		'TND' => array(
1568
-			'admin_label' => sprintf( __('Turkmenistan manat (%1$s)', 'give'), '&#x62f;.&#x62a;'),
1568
+			'admin_label' => sprintf(__('Turkmenistan manat (%1$s)', 'give'), '&#x62f;.&#x62a;'),
1569 1569
 			'symbol'      => '&#x62f;.&#x62a;',
1570 1570
 			'setting'     => array(
1571 1571
 				'currency_position'   => 'before',
@@ -1575,7 +1575,7 @@  discard block
 block discarded – undo
1575 1575
 			),
1576 1576
 		),
1577 1577
 		'TTD' => array(
1578
-			'admin_label' => sprintf( __('Trinidad and Tobago dollar (%1$s)', 'give'), '&#36;'),
1578
+			'admin_label' => sprintf(__('Trinidad and Tobago dollar (%1$s)', 'give'), '&#36;'),
1579 1579
 			'symbol'      => '&#36;',
1580 1580
 			'setting'     => array(
1581 1581
 				'currency_position'   => 'before',
@@ -1585,7 +1585,7 @@  discard block
 block discarded – undo
1585 1585
 			),
1586 1586
 		),
1587 1587
 		'UGX' => array(
1588
-			'admin_label' => sprintf( __('Ugandan shilling (%1$s)', 'give'), 'UGX'),
1588
+			'admin_label' => sprintf(__('Ugandan shilling (%1$s)', 'give'), 'UGX'),
1589 1589
 			'symbol'      => 'UGX',
1590 1590
 			'setting'     => array(
1591 1591
 				'currency_position'   => 'before',
@@ -1595,7 +1595,7 @@  discard block
 block discarded – undo
1595 1595
 			),
1596 1596
 		),
1597 1597
 		'UZS' => array(
1598
-			'admin_label' => sprintf( __('Uzbekistani som (%1$s)', 'give'), 'UZS'),
1598
+			'admin_label' => sprintf(__('Uzbekistani som (%1$s)', 'give'), 'UZS'),
1599 1599
 			'symbol'      => 'UZS',
1600 1600
 			'setting'     => array(
1601 1601
 				'currency_position'   => 'after',
@@ -1605,7 +1605,7 @@  discard block
 block discarded – undo
1605 1605
 			),
1606 1606
 		),
1607 1607
 		'VND' => array(
1608
-			'admin_label' => sprintf( __('Vietnamese đồng (%1$s)', 'give'), '&#8363;'),
1608
+			'admin_label' => sprintf(__('Vietnamese đồng (%1$s)', 'give'), '&#8363;'),
1609 1609
 			'symbol'      => '&#8363;',
1610 1610
 			'setting'     => array(
1611 1611
 				'currency_position'   => 'after',
@@ -1615,7 +1615,7 @@  discard block
 block discarded – undo
1615 1615
 			),
1616 1616
 		),
1617 1617
 		'VUV' => array(
1618
-			'admin_label' => sprintf( __('Vanuatu vatu (%1$s)', 'give'), 'Vt'),
1618
+			'admin_label' => sprintf(__('Vanuatu vatu (%1$s)', 'give'), 'Vt'),
1619 1619
 			'symbol'      => 'Vt',
1620 1620
 			'setting'     => array(
1621 1621
 				'currency_position'   => 'after',
@@ -1625,7 +1625,7 @@  discard block
 block discarded – undo
1625 1625
 			),
1626 1626
 		),
1627 1627
 		'WST' => array(
1628
-			'admin_label' => sprintf( __('Samoan tālā (%1$s)', 'give'), 'T'),
1628
+			'admin_label' => sprintf(__('Samoan tālā (%1$s)', 'give'), 'T'),
1629 1629
 			'symbol'      => 'T',
1630 1630
 			'setting'     => array(
1631 1631
 				'currency_position'   => 'before',
@@ -1635,7 +1635,7 @@  discard block
 block discarded – undo
1635 1635
 			),
1636 1636
 		),
1637 1637
 		'XAF' => array(
1638
-			'admin_label' => sprintf( __('Central African CFA franc (%1$s)', 'give'), 'CFA'),
1638
+			'admin_label' => sprintf(__('Central African CFA franc (%1$s)', 'give'), 'CFA'),
1639 1639
 			'symbol'      => 'CFA',
1640 1640
 			'setting'     => array(
1641 1641
 				'currency_position'   => 'after',
@@ -1645,7 +1645,7 @@  discard block
 block discarded – undo
1645 1645
 			),
1646 1646
 		),
1647 1647
 		'XOF' => array(
1648
-			'admin_label' => sprintf( __('West African CFA franc (%1$s)', 'give'), 'CFA'),
1648
+			'admin_label' => sprintf(__('West African CFA franc (%1$s)', 'give'), 'CFA'),
1649 1649
 			'symbol'      => 'CFA',
1650 1650
 			'setting'     => array(
1651 1651
 				'currency_position'   => 'after',
@@ -1655,7 +1655,7 @@  discard block
 block discarded – undo
1655 1655
 			),
1656 1656
 		),
1657 1657
 		'XPF' => array(
1658
-			'admin_label' => sprintf( __('CFP franc (%1$s)', 'give'), 'Fr'),
1658
+			'admin_label' => sprintf(__('CFP franc (%1$s)', 'give'), 'Fr'),
1659 1659
 			'symbol'      => 'Fr',
1660 1660
 			'setting'     => array(
1661 1661
 				'currency_position'   => 'after',
@@ -1665,7 +1665,7 @@  discard block
 block discarded – undo
1665 1665
 			),
1666 1666
 		),
1667 1667
 		'YER' => array(
1668
-			'admin_label' => sprintf( __('Yemeni rial (%1$s)', 'give'), '&#xfdfc;'),
1668
+			'admin_label' => sprintf(__('Yemeni rial (%1$s)', 'give'), '&#xfdfc;'),
1669 1669
 			'symbol'      => '&#xfdfc;',
1670 1670
 			'setting'     => array(
1671 1671
 				'currency_position'   => 'before',
@@ -1675,7 +1675,7 @@  discard block
 block discarded – undo
1675 1675
 			),
1676 1676
 		),
1677 1677
 		'ZMW' => array(
1678
-			'admin_label' => sprintf( __('Zambian kwacha (%1$s)', 'give'), 'ZK'),
1678
+			'admin_label' => sprintf(__('Zambian kwacha (%1$s)', 'give'), 'ZK'),
1679 1679
 			'symbol'      => 'ZK',
1680 1680
 			'setting'     => array(
1681 1681
 				'currency_position'   => 'before',
@@ -1700,7 +1700,7 @@  discard block
 block discarded – undo
1700 1700
 	 *
1701 1701
 	 * @param array $currencies
1702 1702
 	 */
1703
-	return (array) apply_filters( 'give_currencies', $currencies );
1703
+	return (array) apply_filters('give_currencies', $currencies);
1704 1704
 }
1705 1705
 
1706 1706
 /**
@@ -1712,22 +1712,22 @@  discard block
 block discarded – undo
1712 1712
  *
1713 1713
  * @return array $currencies A list of the available currencies
1714 1714
  */
1715
-function give_get_currencies( $info = 'admin_label' ) {
1715
+function give_get_currencies($info = 'admin_label') {
1716 1716
 
1717 1717
 	$currencies = give_get_currencies_list();
1718 1718
 
1719 1719
 	// Backward compatibility: handle old way of currency registration.
1720 1720
 	// Backward compatibility: Return desired result.
1721
-	if ( ! empty( $currencies ) ) {
1722
-		foreach ( $currencies as $currency_code => $currency_setting ) {
1723
-			if ( is_string( $currency_setting ) ) {
1724
-				$currencies[ $currency_code ] = array(
1721
+	if ( ! empty($currencies)) {
1722
+		foreach ($currencies as $currency_code => $currency_setting) {
1723
+			if (is_string($currency_setting)) {
1724
+				$currencies[$currency_code] = array(
1725 1725
 					'admin_label' => $currency_setting,
1726 1726
 				);
1727 1727
 			}
1728 1728
 
1729
-			$currencies[ $currency_code ] = wp_parse_args(
1730
-				$currencies[ $currency_code ],
1729
+			$currencies[$currency_code] = wp_parse_args(
1730
+				$currencies[$currency_code],
1731 1731
 				array(
1732 1732
 					'admin_label' => '',
1733 1733
 					'symbol'      => $currency_code,
@@ -1736,8 +1736,8 @@  discard block
 block discarded – undo
1736 1736
 			);
1737 1737
 		}
1738 1738
 
1739
-		if ( ! empty( $info ) && is_string( $info ) && 'all' !== $info ) {
1740
-			$currencies = wp_list_pluck( $currencies, $info );
1739
+		if ( ! empty($info) && is_string($info) && 'all' !== $info) {
1740
+			$currencies = wp_list_pluck($currencies, $info);
1741 1741
 		}
1742 1742
 	}
1743 1743
 
@@ -1754,12 +1754,12 @@  discard block
 block discarded – undo
1754 1754
  *
1755 1755
  * @return array
1756 1756
  */
1757
-function give_currency_symbols( $decode_currencies = false ) {
1758
-	$currencies = give_get_currencies( 'symbol' );
1757
+function give_currency_symbols($decode_currencies = false) {
1758
+	$currencies = give_get_currencies('symbol');
1759 1759
 
1760
-	if ( $decode_currencies ) {
1761
-		array_walk( $currencies, function ( &$currency_symbol ) {
1762
-			$currency_symbol = html_entity_decode( $currency_symbol, ENT_COMPAT, 'UTF-8' );
1760
+	if ($decode_currencies) {
1761
+		array_walk($currencies, function(&$currency_symbol) {
1762
+			$currency_symbol = html_entity_decode($currency_symbol, ENT_COMPAT, 'UTF-8');
1763 1763
 		} );
1764 1764
 	}
1765 1765
 
@@ -1770,7 +1770,7 @@  discard block
 block discarded – undo
1770 1770
 	 *
1771 1771
 	 * @param array $currencies
1772 1772
 	 */
1773
-	return apply_filters( 'give_currency_symbols', $currencies );
1773
+	return apply_filters('give_currency_symbols', $currencies);
1774 1774
 }
1775 1775
 
1776 1776
 
@@ -1787,14 +1787,14 @@  discard block
 block discarded – undo
1787 1787
  *
1788 1788
  * @return string           The symbol to use for the currency
1789 1789
  */
1790
-function give_currency_symbol( $currency = '', $decode_currency = false ) {
1790
+function give_currency_symbol($currency = '', $decode_currency = false) {
1791 1791
 
1792
-	if ( empty( $currency ) ) {
1792
+	if (empty($currency)) {
1793 1793
 		$currency = give_get_currency();
1794 1794
 	}
1795 1795
 
1796
-	$currencies = give_currency_symbols( $decode_currency );
1797
-	$symbol     = array_key_exists( $currency, $currencies ) ? $currencies[ $currency ] : $currency;
1796
+	$currencies = give_currency_symbols($decode_currency);
1797
+	$symbol     = array_key_exists($currency, $currencies) ? $currencies[$currency] : $currency;
1798 1798
 
1799 1799
 	/**
1800 1800
 	 * Filter the currency symbol
@@ -1804,7 +1804,7 @@  discard block
 block discarded – undo
1804 1804
 	 * @param string $symbol
1805 1805
 	 * @param string $currency
1806 1806
 	 */
1807
-	return apply_filters( 'give_currency_symbol', $symbol, $currency );
1807
+	return apply_filters('give_currency_symbol', $symbol, $currency);
1808 1808
 }
1809 1809
 
1810 1810
 
@@ -1817,13 +1817,13 @@  discard block
 block discarded – undo
1817 1817
  *
1818 1818
  * @return string
1819 1819
  */
1820
-function give_get_currency_name( $currency_code ) {
1820
+function give_get_currency_name($currency_code) {
1821 1821
 	$currency_name  = '';
1822 1822
 	$currency_names = give_get_currencies();
1823 1823
 
1824
-	if ( $currency_code && array_key_exists( $currency_code, $currency_names ) ) {
1825
-		$currency_name = explode( '(', $currency_names[ $currency_code ] );
1826
-		$currency_name = trim( current( $currency_name ) );
1824
+	if ($currency_code && array_key_exists($currency_code, $currency_names)) {
1825
+		$currency_name = explode('(', $currency_names[$currency_code]);
1826
+		$currency_name = trim(current($currency_name));
1827 1827
 	}
1828 1828
 
1829 1829
 	/**
@@ -1834,7 +1834,7 @@  discard block
 block discarded – undo
1834 1834
 	 * @param string $currency_name
1835 1835
 	 * @param string $currency_code
1836 1836
 	 */
1837
-	return apply_filters( 'give_currency_name', $currency_name, $currency_code );
1837
+	return apply_filters('give_currency_name', $currency_name, $currency_code);
1838 1838
 }
1839 1839
 
1840 1840
 /**
@@ -1847,20 +1847,20 @@  discard block
 block discarded – undo
1847 1847
  *
1848 1848
  * @return mixed|string
1849 1849
  */
1850
-function give_currency_filter( $price = '', $args = array() ) {
1850
+function give_currency_filter($price = '', $args = array()) {
1851 1851
 
1852 1852
 	// Get functions arguments.
1853 1853
 	$func_args = func_get_args();
1854 1854
 
1855 1855
 	// Backward compatibility: modify second param to array
1856
-	if ( isset( $func_args[1] ) && is_string( $func_args[1] ) ) {
1856
+	if (isset($func_args[1]) && is_string($func_args[1])) {
1857 1857
 		$args = array(
1858
-			'currency_code'   => isset( $func_args[1] ) ? $func_args[1] : '',
1859
-			'decode_currency' => isset( $func_args[2] ) ? $func_args[2] : false,
1860
-			'form_id'         => isset( $func_args[3] ) ? $func_args[3] : '',
1858
+			'currency_code'   => isset($func_args[1]) ? $func_args[1] : '',
1859
+			'decode_currency' => isset($func_args[2]) ? $func_args[2] : false,
1860
+			'form_id'         => isset($func_args[3]) ? $func_args[3] : '',
1861 1861
 		);
1862 1862
 
1863
-		give_doing_it_wrong( __FUNCTION__, 'Pass second argument as Array.', GIVE_VERSION );
1863
+		give_doing_it_wrong(__FUNCTION__, 'Pass second argument as Array.', GIVE_VERSION);
1864 1864
 	}
1865 1865
 
1866 1866
 	// Set default values.
@@ -1873,22 +1873,22 @@  discard block
 block discarded – undo
1873 1873
 		)
1874 1874
 	);
1875 1875
 
1876
-	if ( empty( $args['currency_code'] ) || ! array_key_exists( (string) $args['currency_code'], give_get_currencies() ) ) {
1877
-		$args['currency_code'] = give_get_currency( $args['form_id'] );
1876
+	if (empty($args['currency_code']) || ! array_key_exists((string) $args['currency_code'], give_get_currencies())) {
1877
+		$args['currency_code'] = give_get_currency($args['form_id']);
1878 1878
 	}
1879 1879
 
1880
-	$args['position'] = give_get_option( 'currency_position', 'before' );
1880
+	$args['position'] = give_get_option('currency_position', 'before');
1881 1881
 
1882 1882
 	$negative = $price < 0;
1883 1883
 
1884
-	if ( $negative ) {
1884
+	if ($negative) {
1885 1885
 		// Remove proceeding "-".
1886
-		$price = substr( $price, 1 );
1886
+		$price = substr($price, 1);
1887 1887
 	}
1888 1888
 
1889
-	$args['symbol'] = give_currency_symbol( $args['currency_code'], $args['decode_currency'] );
1889
+	$args['symbol'] = give_currency_symbol($args['currency_code'], $args['decode_currency']);
1890 1890
 
1891
-	switch ( $args['currency_code'] ) :
1891
+	switch ($args['currency_code']) :
1892 1892
 		case 'GBP' :
1893 1893
 		case 'BRL' :
1894 1894
 		case 'EUR' :
@@ -1918,13 +1918,13 @@  discard block
 block discarded – undo
1918 1918
 		case 'MAD' :
1919 1919
 		case 'KRW' :
1920 1920
 		case 'ZAR' :
1921
-			$formatted = ( 'before' === $args['position'] ? $args['symbol'] . $price : $price . $args['symbol'] );
1921
+			$formatted = ('before' === $args['position'] ? $args['symbol'].$price : $price.$args['symbol']);
1922 1922
 			break;
1923 1923
 		case 'NOK':
1924
-			$formatted = ( 'before' === $args['position'] ? $args['symbol'] . ' ' . $price : $price . ' ' . $args['symbol'] );
1924
+			$formatted = ('before' === $args['position'] ? $args['symbol'].' '.$price : $price.' '.$args['symbol']);
1925 1925
 			break;
1926 1926
 		default:
1927
-			$formatted = ( 'before' === $args['position'] ? $args['symbol'] . ' ' . $price : $price . ' ' . $args['symbol'] );
1927
+			$formatted = ('before' === $args['position'] ? $args['symbol'].' '.$price : $price.' '.$args['symbol']);
1928 1928
 			break;
1929 1929
 	endswitch;
1930 1930
 
@@ -1933,7 +1933,7 @@  discard block
 block discarded – undo
1933 1933
 	 *
1934 1934
 	 * @since 1.8.17
1935 1935
 	 */
1936
-	$formatted = apply_filters( 'give_currency_filter', $formatted, $args, $price );
1936
+	$formatted = apply_filters('give_currency_filter', $formatted, $args, $price);
1937 1937
 
1938 1938
 	/**
1939 1939
 	 * Filter formatted amount with currency
@@ -1947,16 +1947,16 @@  discard block
 block discarded – undo
1947 1947
 	 *           filter name will be give_usd_currency_filter_after
1948 1948
 	 */
1949 1949
 	$formatted = apply_filters(
1950
-		'give_' . strtolower( $args['currency_code'] ) . "_currency_filter_{$args['position']}",
1950
+		'give_'.strtolower($args['currency_code'])."_currency_filter_{$args['position']}",
1951 1951
 		$formatted,
1952 1952
 		$args['currency_code'],
1953 1953
 		$price,
1954 1954
 		$args
1955 1955
 	);
1956 1956
 
1957
-	if ( $negative ) {
1957
+	if ($negative) {
1958 1958
 		// Prepend the minus sign before the currency sign.
1959
-		$formatted = '-' . $formatted;
1959
+		$formatted = '-'.$formatted;
1960 1960
 	}
1961 1961
 
1962 1962
 	return $formatted;
@@ -1974,7 +1974,7 @@  discard block
 block discarded – undo
1974 1974
  *
1975 1975
  * @return bool
1976 1976
  */
1977
-function give_is_zero_based_currency( $currency = '' ) {
1977
+function give_is_zero_based_currency($currency = '') {
1978 1978
 	$zero_based_currency = array(
1979 1979
 		'JPY', // Japanese Yen.
1980 1980
 		'KRW', // South Korean Won.
@@ -1994,12 +1994,12 @@  discard block
 block discarded – undo
1994 1994
 	);
1995 1995
 
1996 1996
 	// Set default currency.
1997
-	if ( empty( $currency ) ) {
1997
+	if (empty($currency)) {
1998 1998
 		$currency = give_get_currency();
1999 1999
 	}
2000 2000
 
2001 2001
 	// Check for Zero Based Currency.
2002
-	if ( in_array( $currency, $zero_based_currency ) ) {
2002
+	if (in_array($currency, $zero_based_currency)) {
2003 2003
 		return true;
2004 2004
 	}
2005 2005
 
@@ -2014,7 +2014,7 @@  discard block
 block discarded – undo
2014 2014
  *
2015 2015
  * @return bool
2016 2016
  */
2017
-function give_is_right_to_left_supported_currency( $currency = '' ) {
2017
+function give_is_right_to_left_supported_currency($currency = '') {
2018 2018
 	$zero_based_currency = apply_filters(
2019 2019
 		'give_right_to_left_supported_currency',
2020 2020
 		array(
@@ -2038,12 +2038,12 @@  discard block
 block discarded – undo
2038 2038
 	);
2039 2039
 
2040 2040
 	// Set default currency.
2041
-	if ( empty( $currency ) ) {
2041
+	if (empty($currency)) {
2042 2042
 		$currency = give_get_currency();
2043 2043
 	}
2044 2044
 
2045 2045
 	// Check for Zero Based Currency.
2046
-	if ( in_array( $currency, $zero_based_currency ) ) {
2046
+	if (in_array($currency, $zero_based_currency)) {
2047 2047
 		return true;
2048 2048
 	}
2049 2049
 
Please login to merge, or discard this patch.
includes/donors/actions.php 1 patch
Spacing   +27 added lines, -27 removed lines patch added patch discarded remove patch
@@ -8,28 +8,28 @@  discard block
 block discarded – undo
8 8
  * @param array $donation_data
9 9
  *
10 10
  */
11
-function __give_insert_donor_donation_comment( $donation_id, $donation_data ) {
12
-	$is_anonymous_donation = isset( $_POST['give_anonymous_donation'] )
13
-		? absint( $_POST['give_anonymous_donation'] )
11
+function __give_insert_donor_donation_comment($donation_id, $donation_data) {
12
+	$is_anonymous_donation = isset($_POST['give_anonymous_donation'])
13
+		? absint($_POST['give_anonymous_donation'])
14 14
 		: 0;
15 15
 
16
-	if ( ! empty( $_POST['give_comment'] ) ) {
16
+	if ( ! empty($_POST['give_comment'])) {
17 17
 		$comment_id = give_insert_donor_donation_comment(
18 18
 			$donation_id,
19 19
 			$donation_data['user_info']['donor_id'],
20
-			trim( $_POST['give_comment'] ), // We are sanitizing comment in Give_comment:add
21
-			array( 'comment_author_email' => $donation_data['user_info']['email'] )
20
+			trim($_POST['give_comment']), // We are sanitizing comment in Give_comment:add
21
+			array('comment_author_email' => $donation_data['user_info']['email'])
22 22
 		);
23 23
 
24
-		update_comment_meta( $comment_id, '_give_anonymous_donation', $is_anonymous_donation );
25
-		Give()->donor_meta->update_meta( $donation_data['user_info']['donor_id'], '_give_has_comment', '1' );
24
+		update_comment_meta($comment_id, '_give_anonymous_donation', $is_anonymous_donation);
25
+		Give()->donor_meta->update_meta($donation_data['user_info']['donor_id'], '_give_has_comment', '1');
26 26
 	}
27 27
 
28
-	give_update_meta( $donation_id, '_give_anonymous_donation', $is_anonymous_donation );
29
-	Give()->donor_meta->update_meta( $donation_data['user_info']['donor_id'], '_give_anonymous_donor', $is_anonymous_donation );
28
+	give_update_meta($donation_id, '_give_anonymous_donation', $is_anonymous_donation);
29
+	Give()->donor_meta->update_meta($donation_data['user_info']['donor_id'], '_give_anonymous_donor', $is_anonymous_donation);
30 30
 }
31 31
 
32
-add_action( 'give_insert_payment', '__give_insert_donor_donation_comment', 10, 2 );
32
+add_action('give_insert_payment', '__give_insert_donor_donation_comment', 10, 2);
33 33
 
34 34
 
35 35
 /**
@@ -39,16 +39,16 @@  discard block
 block discarded – undo
39 39
  */
40 40
 function __give_validate_donor_comment() {
41 41
 	// Check wp_check_comment_data_max_lengths for comment length validation.
42
-	if ( ! empty( $_POST['give_comment'] ) ) {
42
+	if ( ! empty($_POST['give_comment'])) {
43 43
 		$max_lengths = wp_get_comment_fields_max_lengths();
44
-		$comment     = give_clean( $_POST['give_comment'] );
44
+		$comment     = give_clean($_POST['give_comment']);
45 45
 
46
-		if ( mb_strlen( $comment, '8bit' ) > $max_lengths['comment_content'] ) {
47
-			give_set_error( 'comment_content_column_length', __( 'Your comment is too long.', 'give' ) );
46
+		if (mb_strlen($comment, '8bit') > $max_lengths['comment_content']) {
47
+			give_set_error('comment_content_column_length', __('Your comment is too long.', 'give'));
48 48
 		}
49 49
 	}
50 50
 }
51
-add_action( 'give_checkout_error_checks', '__give_validate_donor_comment', 10, 1 );
51
+add_action('give_checkout_error_checks', '__give_validate_donor_comment', 10, 1);
52 52
 
53 53
 
54 54
 /**
@@ -59,18 +59,18 @@  discard block
 block discarded – undo
59 59
  * @param $donation_id
60 60
  * @param $status
61 61
  */
62
-function __give_update_donor_donation_comment_status( $donation_id, $status ) {
63
-	$approve = absint( 'publish' === $status );
62
+function __give_update_donor_donation_comment_status($donation_id, $status) {
63
+	$approve = absint('publish' === $status);
64 64
 
65 65
 	/* @var WP_Comment $note */
66
-	$donor_comment = give_get_donor_donation_comment( $donation_id, give_get_payment_donor_id( $donation_id ) );
66
+	$donor_comment = give_get_donor_donation_comment($donation_id, give_get_payment_donor_id($donation_id));
67 67
 
68
-	if( $donor_comment instanceof WP_Comment ) {
69
-		wp_set_comment_status( $donor_comment->comment_ID, (string) $approve );
68
+	if ($donor_comment instanceof WP_Comment) {
69
+		wp_set_comment_status($donor_comment->comment_ID, (string) $approve);
70 70
 	}
71 71
 }
72 72
 
73
-add_action( 'give_update_payment_status', '__give_update_donor_donation_comment_status', 10, 2 );
73
+add_action('give_update_payment_status', '__give_update_donor_donation_comment_status', 10, 2);
74 74
 
75 75
 /**
76 76
  * Remove donor comment when donation delete
@@ -79,13 +79,13 @@  discard block
 block discarded – undo
79 79
  *
80 80
  * @param $donation_id
81 81
  */
82
-function __give_remove_donor_donation_comment( $donation_id ) {
82
+function __give_remove_donor_donation_comment($donation_id) {
83 83
 	/* @var WP_Comment $note */
84
-	$donor_comment = give_get_donor_donation_comment( $donation_id, give_get_payment_donor_id( $donation_id ) );
84
+	$donor_comment = give_get_donor_donation_comment($donation_id, give_get_payment_donor_id($donation_id));
85 85
 
86
-	if( $donor_comment instanceof WP_Comment ) {
87
-		wp_delete_comment( $donor_comment->comment_ID );
86
+	if ($donor_comment instanceof WP_Comment) {
87
+		wp_delete_comment($donor_comment->comment_ID);
88 88
 	}
89 89
 }
90 90
 
91
-add_action( 'give_payment_deleted', '__give_remove_donor_donation_comment', 10 );
91
+add_action('give_payment_deleted', '__give_remove_donor_donation_comment', 10);
Please login to merge, or discard this patch.
includes/class-give-html-elements.php 1 patch
Spacing   +159 added lines, -159 removed lines patch added patch discarded remove patch
@@ -10,7 +10,7 @@  discard block
 block discarded – undo
10 10
  */
11 11
 
12 12
 // Exit if accessed directly.
13
-if ( ! defined( 'ABSPATH' ) ) {
13
+if ( ! defined('ABSPATH')) {
14 14
 	exit;
15 15
 }
16 16
 
@@ -35,7 +35,7 @@  discard block
 block discarded – undo
35 35
 	 *
36 36
 	 * @return string       Donations dropdown.
37 37
 	 */
38
-	public function donations_dropdown( $args = array() ) {
38
+	public function donations_dropdown($args = array()) {
39 39
 
40 40
 		$defaults = array(
41 41
 			'name'        => 'donations',
@@ -45,32 +45,32 @@  discard block
 block discarded – undo
45 45
 			'selected'    => 0,
46 46
 			'chosen'      => false,
47 47
 			'number'      => 30,
48
-			'placeholder' => __( 'Select a donation', 'give' ),
48
+			'placeholder' => __('Select a donation', 'give'),
49 49
 		);
50 50
 
51
-		$args = wp_parse_args( $args, $defaults );
51
+		$args = wp_parse_args($args, $defaults);
52 52
 
53
-		$payments = new Give_Payments_Query( array(
53
+		$payments = new Give_Payments_Query(array(
54 54
 			'number' => $args['number'],
55
-		) );
55
+		));
56 56
 
57 57
 		$payments = $payments->get_payments();
58 58
 
59 59
 		$options = array();
60 60
 
61 61
 		// Provide nice human readable options.
62
-		if ( $payments ) {
62
+		if ($payments) {
63 63
 			$options[0] = $args['placeholder'];
64
-			foreach ( $payments as $payment ) {
64
+			foreach ($payments as $payment) {
65 65
 
66
-				$options[ absint( $payment->ID ) ] = esc_html( '#' . $payment->ID . ' - ' . $payment->email . ' - ' . $payment->form_title );
66
+				$options[absint($payment->ID)] = esc_html('#'.$payment->ID.' - '.$payment->email.' - '.$payment->form_title);
67 67
 
68 68
 			}
69 69
 		} else {
70
-			$options[0] = __( 'No donations found.', 'give' );
70
+			$options[0] = __('No donations found.', 'give');
71 71
 		}
72 72
 
73
-		$output = $this->select( array(
73
+		$output = $this->select(array(
74 74
 			'name'             => $args['name'],
75 75
 			'selected'         => $args['selected'],
76 76
 			'id'               => $args['id'],
@@ -82,7 +82,7 @@  discard block
 block discarded – undo
82 82
 			'select_atts'      => $args['select_atts'],
83 83
 			'show_option_all'  => false,
84 84
 			'show_option_none' => false,
85
-		) );
85
+		));
86 86
 
87 87
 		return $output;
88 88
 	}
@@ -99,7 +99,7 @@  discard block
 block discarded – undo
99 99
 	 *
100 100
 	 * @return string      Give forms dropdown.
101 101
 	 */
102
-	public function forms_dropdown( $args = array() ) {
102
+	public function forms_dropdown($args = array()) {
103 103
 
104 104
 		$defaults = array(
105 105
 			'name'        => 'forms',
@@ -109,14 +109,14 @@  discard block
 block discarded – undo
109 109
 			'selected'    => 0,
110 110
 			'chosen'      => false,
111 111
 			'number'      => 30,
112
-			'placeholder' => esc_attr__( 'All Forms', 'give' ),
112
+			'placeholder' => esc_attr__('All Forms', 'give'),
113 113
 			'data'        => array(
114 114
 				'search-type' => 'form',
115 115
 			),
116 116
 			'query_args' => array()
117 117
 		);
118 118
 
119
-		$args = wp_parse_args( $args, $defaults );
119
+		$args = wp_parse_args($args, $defaults);
120 120
 
121 121
 		$form_args = wp_parse_args(
122 122
 			$args['query_args'],
@@ -128,37 +128,37 @@  discard block
 block discarded – undo
128 128
 			)
129 129
 		);
130 130
 
131
-		$cache_key   = Give_Cache::get_key( 'give_forms', $form_args, false );
131
+		$cache_key = Give_Cache::get_key('give_forms', $form_args, false);
132 132
 
133 133
 		// Get forms from cache.
134
-		$forms = Give_Cache::get_db_query( $cache_key );
134
+		$forms = Give_Cache::get_db_query($cache_key);
135 135
 
136
-		if ( is_null( $forms ) ) {
137
-			$forms = new WP_Query( $form_args );
136
+		if (is_null($forms)) {
137
+			$forms = new WP_Query($form_args);
138 138
 			$forms = $forms->posts;
139
-			Give_Cache::set_db_query( $cache_key, $forms );
139
+			Give_Cache::set_db_query($cache_key, $forms);
140 140
 		}
141 141
 
142 142
 		$options = array();
143 143
 
144 144
 		// Ensure the selected.
145
-		if ( false !== $args['selected'] && $args['selected'] !== 0 ) {
146
-			$options[ $args['selected'] ] = get_the_title( $args['selected'] );
145
+		if (false !== $args['selected'] && $args['selected'] !== 0) {
146
+			$options[$args['selected']] = get_the_title($args['selected']);
147 147
 		}
148 148
 
149
-		$options[0] = esc_html__( 'No forms found.', 'give' );
150
-		if ( ! empty( $forms ) ) {
149
+		$options[0] = esc_html__('No forms found.', 'give');
150
+		if ( ! empty($forms)) {
151 151
 			$options[0] = $args['placeholder'];
152
-			foreach ( $forms as $form ) {
153
-				$form_title = empty( $form->post_title )
154
-					? sprintf( __( 'Untitled (#%s)', 'give' ), $form->ID )
152
+			foreach ($forms as $form) {
153
+				$form_title = empty($form->post_title)
154
+					? sprintf(__('Untitled (#%s)', 'give'), $form->ID)
155 155
 					: $form->post_title;
156 156
 
157
-				$options[ absint( $form->ID ) ] = esc_html( $form_title );
157
+				$options[absint($form->ID)] = esc_html($form_title);
158 158
 			}
159 159
 		}
160 160
 
161
-		$output = $this->select( array(
161
+		$output = $this->select(array(
162 162
 			'name'             => $args['name'],
163 163
 			'selected'         => $args['selected'],
164 164
 			'id'               => $args['id'],
@@ -170,7 +170,7 @@  discard block
 block discarded – undo
170 170
 			'show_option_all'  => false,
171 171
 			'show_option_none' => false,
172 172
 			'data'             => $args['data'],
173
-		) );
173
+		));
174 174
 
175 175
 		return $output;
176 176
 	}
@@ -187,7 +187,7 @@  discard block
 block discarded – undo
187 187
 	 *
188 188
 	 * @return string      Donors dropdown.
189 189
 	 */
190
-	public function donor_dropdown( $args = array() ) {
190
+	public function donor_dropdown($args = array()) {
191 191
 
192 192
 		$defaults = array(
193 193
 			'name'        => 'donors',
@@ -196,58 +196,58 @@  discard block
 block discarded – undo
196 196
 			'multiple'    => false,
197 197
 			'selected'    => 0,
198 198
 			'chosen'      => true,
199
-			'placeholder' => esc_attr__( 'Select a Donor', 'give' ),
199
+			'placeholder' => esc_attr__('Select a Donor', 'give'),
200 200
 			'number'      => 30,
201 201
 			'data'        => array(
202 202
 				'search-type' => 'donor',
203 203
 			),
204 204
 		);
205 205
 
206
-		$args = wp_parse_args( $args, $defaults );
206
+		$args = wp_parse_args($args, $defaults);
207 207
 
208
-		$donors = Give()->donors->get_donors( array(
208
+		$donors = Give()->donors->get_donors(array(
209 209
 			'number' => $args['number'],
210
-		) );
210
+		));
211 211
 
212 212
 		$options = array();
213 213
 
214
-		if ( $donors ) {
215
-			$options[0] = esc_html__( 'No donor attached', 'give' );
216
-			foreach ( $donors as $donor ) {
217
-				$donor = give_get_name_with_title_prefixes( $donor );
218
-				$options[ absint( $donor->id ) ] = esc_html( $donor->name . ' (' . $donor->email . ')' );
214
+		if ($donors) {
215
+			$options[0] = esc_html__('No donor attached', 'give');
216
+			foreach ($donors as $donor) {
217
+				$donor = give_get_name_with_title_prefixes($donor);
218
+				$options[absint($donor->id)] = esc_html($donor->name.' ('.$donor->email.')');
219 219
 			}
220 220
 		} else {
221
-			$options[0] = esc_html__( 'No donors found.', 'give' );
221
+			$options[0] = esc_html__('No donors found.', 'give');
222 222
 		}
223 223
 
224
-		if ( ! empty( $args['selected'] ) ) {
224
+		if ( ! empty($args['selected'])) {
225 225
 
226 226
 			// If a selected customer has been specified, we need to ensure it's in the initial list of customers displayed.
227
-			if ( ! array_key_exists( $args['selected'], $options ) ) {
227
+			if ( ! array_key_exists($args['selected'], $options)) {
228 228
 
229
-				$donor = new Give_Donor( $args['selected'] );
229
+				$donor = new Give_Donor($args['selected']);
230 230
 
231
-				if ( $donor ) {
232
-					$donor = give_get_name_with_title_prefixes( $donor );
233
-					$options[ absint( $args['selected'] ) ] = esc_html( $donor->name . ' (' . $donor->email . ')' );
231
+				if ($donor) {
232
+					$donor = give_get_name_with_title_prefixes($donor);
233
+					$options[absint($args['selected'])] = esc_html($donor->name.' ('.$donor->email.')');
234 234
 
235 235
 				}
236 236
 			}
237 237
 		}
238 238
 
239
-		$output = $this->select( array(
239
+		$output = $this->select(array(
240 240
 			'name'             => $args['name'],
241 241
 			'selected'         => $args['selected'],
242 242
 			'id'               => $args['id'],
243
-			'class'            => $args['class'] . ' give-customer-select',
243
+			'class'            => $args['class'].' give-customer-select',
244 244
 			'options'          => $options,
245 245
 			'multiple'         => $args['multiple'],
246 246
 			'chosen'           => $args['chosen'],
247 247
 			'show_option_all'  => false,
248 248
 			'show_option_none' => false,
249 249
 			'data'             => $args['data'],
250
-		) );
250
+		));
251 251
 
252 252
 		return $output;
253 253
 	}
@@ -266,22 +266,22 @@  discard block
 block discarded – undo
266 266
 	 *
267 267
 	 * @return string           Categories dropdown.
268 268
 	 */
269
-	public function category_dropdown( $name = 'give_forms_categories', $selected = 0, $args = array() ) {
270
-		$categories = get_terms( 'give_forms_category', apply_filters( 'give_forms_category_dropdown', array() ) );
269
+	public function category_dropdown($name = 'give_forms_categories', $selected = 0, $args = array()) {
270
+		$categories = get_terms('give_forms_category', apply_filters('give_forms_category_dropdown', array()));
271 271
 
272 272
 		$options = array();
273 273
 
274
-		foreach ( $categories as $category ) {
275
-			$options[ absint( $category->term_id ) ] = esc_html( $category->name );
274
+		foreach ($categories as $category) {
275
+			$options[absint($category->term_id)] = esc_html($category->name);
276 276
 		}
277 277
 
278
-		$output = $this->select( wp_parse_args( $args, array(
278
+		$output = $this->select(wp_parse_args($args, array(
279 279
 			'name'             => $name,
280 280
 			'selected'         => $selected,
281 281
 			'options'          => $options,
282
-			'show_option_all'  => esc_html__( 'All Categories', 'give' ),
282
+			'show_option_all'  => esc_html__('All Categories', 'give'),
283 283
 			'show_option_none' => false,
284
-		) ) );
284
+		)));
285 285
 
286 286
 		return $output;
287 287
 	}
@@ -300,22 +300,22 @@  discard block
 block discarded – undo
300 300
 	 *
301 301
 	 * @return string           Tags dropdown.
302 302
 	 */
303
-	public function tags_dropdown( $name = 'give_forms_tags', $selected = 0, $args = array() ) {
304
-		$tags    = get_terms( 'give_forms_tag', apply_filters( 'give_forms_tag_dropdown', array() ) );
303
+	public function tags_dropdown($name = 'give_forms_tags', $selected = 0, $args = array()) {
304
+		$tags    = get_terms('give_forms_tag', apply_filters('give_forms_tag_dropdown', array()));
305 305
 
306 306
 		$options = array();
307 307
 
308
-		foreach ( $tags as $tag ) {
309
-			$options[ absint( $tag->term_id ) ] = esc_html( $tag->name );
308
+		foreach ($tags as $tag) {
309
+			$options[absint($tag->term_id)] = esc_html($tag->name);
310 310
 		}
311 311
 
312
-		$output = $this->select( wp_parse_args( $args, array(
312
+		$output = $this->select(wp_parse_args($args, array(
313 313
 			'name'             => $name,
314 314
 			'selected'         => $selected,
315 315
 			'options'          => $options,
316
-			'show_option_all'  => esc_html__( 'All Tags', 'give' ),
316
+			'show_option_all'  => esc_html__('All Tags', 'give'),
317 317
 			'show_option_none' => false,
318
-		) ) );
318
+		)));
319 319
 
320 320
 		return $output;
321 321
 	}
@@ -335,25 +335,25 @@  discard block
 block discarded – undo
335 335
 	 *
336 336
 	 * @return string               Years dropdown.
337 337
 	 */
338
-	public function year_dropdown( $name = 'year', $selected = 0, $years_before = 5, $years_after = 0 ) {
339
-		$current    = date( 'Y' );
340
-		$start_year = $current - absint( $years_before );
341
-		$end_year   = $current + absint( $years_after );
342
-		$selected   = empty( $selected ) ? date( 'Y' ) : $selected;
338
+	public function year_dropdown($name = 'year', $selected = 0, $years_before = 5, $years_after = 0) {
339
+		$current    = date('Y');
340
+		$start_year = $current - absint($years_before);
341
+		$end_year   = $current + absint($years_after);
342
+		$selected   = empty($selected) ? date('Y') : $selected;
343 343
 		$options    = array();
344 344
 
345
-		while ( $start_year <= $end_year ) {
346
-			$options[ absint( $start_year ) ] = $start_year;
347
-			$start_year ++;
345
+		while ($start_year <= $end_year) {
346
+			$options[absint($start_year)] = $start_year;
347
+			$start_year++;
348 348
 		}
349 349
 
350
-		$output = $this->select( array(
350
+		$output = $this->select(array(
351 351
 			'name'             => $name,
352 352
 			'selected'         => $selected,
353 353
 			'options'          => $options,
354 354
 			'show_option_all'  => false,
355 355
 			'show_option_none' => false,
356
-		) );
356
+		));
357 357
 
358 358
 		return $output;
359 359
 	}
@@ -371,23 +371,23 @@  discard block
 block discarded – undo
371 371
 	 *
372 372
 	 * @return string           Months dropdown.
373 373
 	 */
374
-	public function month_dropdown( $name = 'month', $selected = 0 ) {
374
+	public function month_dropdown($name = 'month', $selected = 0) {
375 375
 		$month    = 1;
376 376
 		$options  = array();
377
-		$selected = empty( $selected ) ? date( 'n' ) : $selected;
377
+		$selected = empty($selected) ? date('n') : $selected;
378 378
 
379
-		while ( $month <= 12 ) {
380
-			$options[ absint( $month ) ] = give_month_num_to_name( $month );
381
-			$month ++;
379
+		while ($month <= 12) {
380
+			$options[absint($month)] = give_month_num_to_name($month);
381
+			$month++;
382 382
 		}
383 383
 
384
-		$output = $this->select( array(
384
+		$output = $this->select(array(
385 385
 			'name'             => $name,
386 386
 			'selected'         => $selected,
387 387
 			'options'          => $options,
388 388
 			'show_option_all'  => false,
389 389
 			'show_option_none' => false,
390
-		) );
390
+		));
391 391
 
392 392
 		return $output;
393 393
 	}
@@ -404,7 +404,7 @@  discard block
 block discarded – undo
404 404
 	 *
405 405
 	 * @return string      The dropdown.
406 406
 	 */
407
-	public function select( $args = array() ) {
407
+	public function select($args = array()) {
408 408
 		$defaults = array(
409 409
 			'options'          => array(),
410 410
 			'name'             => null,
@@ -415,74 +415,74 @@  discard block
 block discarded – undo
415 415
 			'placeholder'      => null,
416 416
 			'multiple'         => false,
417 417
 			'select_atts'      => false,
418
-			'show_option_all'  => __( 'All', 'give' ),
419
-			'show_option_none' => __( 'None', 'give' ),
418
+			'show_option_all'  => __('All', 'give'),
419
+			'show_option_none' => __('None', 'give'),
420 420
 			'data'             => array(),
421 421
 			'readonly'         => false,
422 422
 			'disabled'         => false,
423 423
 		);
424 424
 
425
-		$args = wp_parse_args( $args, $defaults );
425
+		$args = wp_parse_args($args, $defaults);
426 426
 
427 427
 		$data_elements = '';
428
-		foreach ( $args['data'] as $key => $value ) {
429
-			$data_elements .= ' data-' . esc_attr( $key ) . '="' . esc_attr( $value ) . '"';
428
+		foreach ($args['data'] as $key => $value) {
429
+			$data_elements .= ' data-'.esc_attr($key).'="'.esc_attr($value).'"';
430 430
 		}
431 431
 
432 432
 		$multiple = '';
433
-		if ( $args['multiple'] ) {
433
+		if ($args['multiple']) {
434 434
 			$multiple = 'MULTIPLE';
435 435
 		}
436 436
 
437
-		if ( $args['chosen'] ) {
437
+		if ($args['chosen']) {
438 438
 			$args['class'] .= ' give-select-chosen';
439 439
 		}
440 440
 
441 441
 		$placeholder = '';
442
-		if ( $args['placeholder'] ) {
442
+		if ($args['placeholder']) {
443 443
 			$placeholder = $args['placeholder'];
444 444
 		}
445 445
 
446 446
 		$output = sprintf(
447 447
 			'<select name="%1$s" id="%2$s" autocomplete="address-level4" class="give-select %3$s" %4$s %5$s placeholder="%6$s" data-placeholder="%6$s" %7$s>',
448
-			esc_attr( $args['name'] ),
449
-			esc_attr( sanitize_key( str_replace( '-', '_', $args['id'] ) ) ),
450
-			esc_attr( $args['class'] ),
448
+			esc_attr($args['name']),
449
+			esc_attr(sanitize_key(str_replace('-', '_', $args['id']))),
450
+			esc_attr($args['class']),
451 451
 			$multiple,
452 452
 			$args['select_atts'],
453 453
 			$placeholder,
454 454
 			$data_elements
455 455
 		);
456 456
 
457
-		if ( $args['show_option_all'] ) {
458
-			if ( $args['multiple'] ) {
459
-				$selected = selected( true, in_array( 0, $args['selected'] ), false );
457
+		if ($args['show_option_all']) {
458
+			if ($args['multiple']) {
459
+				$selected = selected(true, in_array(0, $args['selected']), false);
460 460
 			} else {
461
-				$selected = selected( $args['selected'], 0, false );
461
+				$selected = selected($args['selected'], 0, false);
462 462
 			}
463
-			$output .= '<option value="all"' . $selected . '>' . esc_html( $args['show_option_all'] ) . '</option>';
463
+			$output .= '<option value="all"'.$selected.'>'.esc_html($args['show_option_all']).'</option>';
464 464
 		}
465 465
 
466
-		if ( ! empty( $args['options'] ) ) {
466
+		if ( ! empty($args['options'])) {
467 467
 
468
-			if ( $args['show_option_none'] ) {
469
-				if ( $args['multiple'] ) {
470
-					$selected = selected( true, in_array( - 1, $args['selected'] ), false );
468
+			if ($args['show_option_none']) {
469
+				if ($args['multiple']) {
470
+					$selected = selected(true, in_array( -1, $args['selected'] ), false);
471 471
 				} else {
472
-					$selected = selected( $args['selected'], - 1, false );
472
+					$selected = selected($args['selected'], - 1, false);
473 473
 				}
474
-				$output .= '<option value="-1"' . $selected . '>' . esc_html( $args['show_option_none'] ) . '</option>';
474
+				$output .= '<option value="-1"'.$selected.'>'.esc_html($args['show_option_none']).'</option>';
475 475
 			}
476 476
 
477
-			foreach ( $args['options'] as $key => $option ) {
477
+			foreach ($args['options'] as $key => $option) {
478 478
 
479
-				if ( $args['multiple'] && is_array( $args['selected'] ) ) {
480
-					$selected = selected( true, in_array( $key, $args['selected'] ), false );
479
+				if ($args['multiple'] && is_array($args['selected'])) {
480
+					$selected = selected(true, in_array($key, $args['selected']), false);
481 481
 				} else {
482
-					$selected = selected( $args['selected'], $key, false );
482
+					$selected = selected($args['selected'], $key, false);
483 483
 				}
484 484
 
485
-				$output .= '<option value="' . esc_attr( $key ) . '"' . $selected . '>' . esc_html( $option ) . '</option>';
485
+				$output .= '<option value="'.esc_attr($key).'"'.$selected.'>'.esc_html($option).'</option>';
486 486
 			}
487 487
 		}
488 488
 
@@ -503,7 +503,7 @@  discard block
 block discarded – undo
503 503
 	 *
504 504
 	 * @return string      The checkbox.
505 505
 	 */
506
-	public function checkbox( $args = array() ) {
506
+	public function checkbox($args = array()) {
507 507
 		$defaults = array(
508 508
 			'name'    => null,
509 509
 			'current' => null,
@@ -514,16 +514,16 @@  discard block
 block discarded – undo
514 514
 			),
515 515
 		);
516 516
 
517
-		$args = wp_parse_args( $args, $defaults );
517
+		$args = wp_parse_args($args, $defaults);
518 518
 
519 519
 		$options = '';
520
-		if ( ! empty( $args['options']['disabled'] ) ) {
520
+		if ( ! empty($args['options']['disabled'])) {
521 521
 			$options .= ' disabled="disabled"';
522
-		} elseif ( ! empty( $args['options']['readonly'] ) ) {
522
+		} elseif ( ! empty($args['options']['readonly'])) {
523 523
 			$options .= ' readonly';
524 524
 		}
525 525
 
526
-		$output = '<input type="checkbox"' . $options . ' name="' . esc_attr( $args['name'] ) . '" id="' . esc_attr( $args['name'] ) . '" class="' . $args['class'] . ' ' . esc_attr( $args['name'] ) . '" ' . checked( 1, $args['current'], false ) . ' />';
526
+		$output = '<input type="checkbox"'.$options.' name="'.esc_attr($args['name']).'" id="'.esc_attr($args['name']).'" class="'.$args['class'].' '.esc_attr($args['name']).'" '.checked(1, $args['current'], false).' />';
527 527
 
528 528
 		return $output;
529 529
 	}
@@ -540,22 +540,22 @@  discard block
 block discarded – undo
540 540
 	 *
541 541
 	 * @return string      The text field.
542 542
 	 */
543
-	public function text( $args = array() ) {
543
+	public function text($args = array()) {
544 544
 		// Backwards compatibility.
545
-		if ( func_num_args() > 1 ) {
545
+		if (func_num_args() > 1) {
546 546
 			$args = func_get_args();
547 547
 
548 548
 			$name  = $args[0];
549
-			$value = isset( $args[1] ) ? $args[1] : '';
550
-			$label = isset( $args[2] ) ? $args[2] : '';
551
-			$desc  = isset( $args[3] ) ? $args[3] : '';
549
+			$value = isset($args[1]) ? $args[1] : '';
550
+			$label = isset($args[2]) ? $args[2] : '';
551
+			$desc  = isset($args[3]) ? $args[3] : '';
552 552
 		}
553 553
 
554 554
 		$defaults = array(
555
-			'name'         => isset( $name ) ? $name : 'text',
556
-			'value'        => isset( $value ) ? $value : null,
557
-			'label'        => isset( $label ) ? $label : null,
558
-			'desc'         => isset( $desc ) ? $desc : null,
555
+			'name'         => isset($name) ? $name : 'text',
556
+			'value'        => isset($value) ? $value : null,
557
+			'label'        => isset($label) ? $label : null,
558
+			'desc'         => isset($desc) ? $desc : null,
559 559
 			'placeholder'  => '',
560 560
 			'class'        => 'regular-text',
561 561
 			'disabled'     => false,
@@ -563,29 +563,29 @@  discard block
 block discarded – undo
563 563
 			'data'         => false,
564 564
 		);
565 565
 
566
-		$args = wp_parse_args( $args, $defaults );
566
+		$args = wp_parse_args($args, $defaults);
567 567
 
568 568
 		$disabled = '';
569
-		if ( $args['disabled'] ) {
569
+		if ($args['disabled']) {
570 570
 			$disabled = ' disabled="disabled"';
571 571
 		}
572 572
 
573 573
 		$data = '';
574
-		if ( ! empty( $args['data'] ) ) {
575
-			foreach ( $args['data'] as $key => $value ) {
576
-				$data .= 'data-' . $key . '="' . $value . '" ';
574
+		if ( ! empty($args['data'])) {
575
+			foreach ($args['data'] as $key => $value) {
576
+				$data .= 'data-'.$key.'="'.$value.'" ';
577 577
 			}
578 578
 		}
579 579
 
580
-		$output = '<span id="give-' . sanitize_key( $args['name'] ) . '-wrap">';
580
+		$output = '<span id="give-'.sanitize_key($args['name']).'-wrap">';
581 581
 
582
-		$output .= '<label class="give-label" for="give-' . sanitize_key( $args['name'] ) . '">' . esc_html( $args['label'] ) . '</label>';
582
+		$output .= '<label class="give-label" for="give-'.sanitize_key($args['name']).'">'.esc_html($args['label']).'</label>';
583 583
 
584
-		if ( ! empty( $args['desc'] ) ) {
585
-			$output .= '<span class="give-description">' . esc_html( $args['desc'] ) . '</span>';
584
+		if ( ! empty($args['desc'])) {
585
+			$output .= '<span class="give-description">'.esc_html($args['desc']).'</span>';
586 586
 		}
587 587
 
588
-		$output .= '<input type="text" name="' . esc_attr( $args['name'] ) . '" id="' . esc_attr( $args['name'] ) . '" autocomplete="' . esc_attr( $args['autocomplete'] ) . '" value="' . esc_attr( $args['value'] ) . '" placeholder="' . esc_attr( $args['placeholder'] ) . '" class="' . $args['class'] . '" ' . $data . '' . $disabled . '/>';
588
+		$output .= '<input type="text" name="'.esc_attr($args['name']).'" id="'.esc_attr($args['name']).'" autocomplete="'.esc_attr($args['autocomplete']).'" value="'.esc_attr($args['value']).'" placeholder="'.esc_attr($args['placeholder']).'" class="'.$args['class'].'" '.$data.''.$disabled.'/>';
589 589
 
590 590
 		$output .= '</span>';
591 591
 
@@ -604,15 +604,15 @@  discard block
 block discarded – undo
604 604
 	 *
605 605
 	 * @return string      The date picker.
606 606
 	 */
607
-	public function date_field( $args = array() ) {
607
+	public function date_field($args = array()) {
608 608
 
609
-		if ( empty( $args['class'] ) ) {
609
+		if (empty($args['class'])) {
610 610
 			$args['class'] = 'give_datepicker';
611
-		} elseif ( ! strpos( $args['class'], 'give_datepicker' ) ) {
611
+		} elseif ( ! strpos($args['class'], 'give_datepicker')) {
612 612
 			$args['class'] .= ' give_datepicker';
613 613
 		}
614 614
 
615
-		return $this->text( $args );
615
+		return $this->text($args);
616 616
 	}
617 617
 
618 618
 	/**
@@ -627,7 +627,7 @@  discard block
 block discarded – undo
627 627
 	 *
628 628
 	 * @return string      The textarea.
629 629
 	 */
630
-	public function textarea( $args = array() ) {
630
+	public function textarea($args = array()) {
631 631
 		$defaults = array(
632 632
 			'name'     => 'textarea',
633 633
 			'value'    => null,
@@ -637,21 +637,21 @@  discard block
 block discarded – undo
637 637
 			'disabled' => false,
638 638
 		);
639 639
 
640
-		$args = wp_parse_args( $args, $defaults );
640
+		$args = wp_parse_args($args, $defaults);
641 641
 
642 642
 		$disabled = '';
643
-		if ( $args['disabled'] ) {
643
+		if ($args['disabled']) {
644 644
 			$disabled = ' disabled="disabled"';
645 645
 		}
646 646
 
647
-		$output = '<span id="give-' . sanitize_key( $args['name'] ) . '-wrap">';
647
+		$output = '<span id="give-'.sanitize_key($args['name']).'-wrap">';
648 648
 
649
-		$output .= '<label class="give-label" for="give-' . sanitize_key( $args['name'] ) . '">' . esc_html( $args['label'] ) . '</label>';
649
+		$output .= '<label class="give-label" for="give-'.sanitize_key($args['name']).'">'.esc_html($args['label']).'</label>';
650 650
 
651
-		$output .= '<textarea name="' . esc_attr( $args['name'] ) . '" id="' . esc_attr( $args['name'] ) . '" class="' . $args['class'] . '"' . $disabled . '>' . esc_attr( $args['value'] ) . '</textarea>';
651
+		$output .= '<textarea name="'.esc_attr($args['name']).'" id="'.esc_attr($args['name']).'" class="'.$args['class'].'"'.$disabled.'>'.esc_attr($args['value']).'</textarea>';
652 652
 
653
-		if ( ! empty( $args['desc'] ) ) {
654
-			$output .= '<span class="give-description">' . esc_html( $args['desc'] ) . '</span>';
653
+		if ( ! empty($args['desc'])) {
654
+			$output .= '<span class="give-description">'.esc_html($args['desc']).'</span>';
655 655
 		}
656 656
 
657 657
 		$output .= '</span>';
@@ -671,7 +671,7 @@  discard block
 block discarded – undo
671 671
 	 *
672 672
 	 * @return string      The text field with ajax search.
673 673
 	 */
674
-	public function ajax_user_search( $args = array() ) {
674
+	public function ajax_user_search($args = array()) {
675 675
 
676 676
 		$defaults = array(
677 677
 			'name'        => 'users',
@@ -682,13 +682,13 @@  discard block
 block discarded – undo
682 682
 			'chosen'      => true,
683 683
 			'number'      => 30,
684 684
 			'select_atts' => '',
685
-			'placeholder' => __( 'Select a user', 'give' ),
685
+			'placeholder' => __('Select a user', 'give'),
686 686
 			'data'        => array(
687 687
 				'search-type' => 'user',
688 688
 			),
689 689
 		);
690 690
 
691
-		$args = wp_parse_args( $args, $defaults );
691
+		$args = wp_parse_args($args, $defaults);
692 692
 
693 693
 		// Set initial args.
694 694
 		$get_users_args = array(
@@ -697,31 +697,31 @@  discard block
 block discarded – undo
697 697
 
698 698
 		// Ensure selected user is not included in initial query.
699 699
 		// This is because sites with many users, it's not a guarantee the selected user will be returned.
700
-		if ( ! empty( $args['selected'] ) ) {
700
+		if ( ! empty($args['selected'])) {
701 701
 			$get_users_args['exclude'] = $args['selected'];
702 702
 		}
703 703
 
704 704
 		// Initial users array.
705
-		$users = apply_filters( 'give_ajax_user_search_initial_results', get_users( $get_users_args ), $args );
705
+		$users = apply_filters('give_ajax_user_search_initial_results', get_users($get_users_args), $args);
706 706
 
707 707
 		// Now add the selected user to the $users array if the arg is present.
708
-		if ( ! empty( $args['selected'] ) ) {
709
-			$selected_user =  apply_filters( 'give_ajax_user_search_selected_results', get_users( "include={$args['selected']}" ), $args );;
710
-			$users         = array_merge( $users, $selected_user );
708
+		if ( ! empty($args['selected'])) {
709
+			$selected_user = apply_filters('give_ajax_user_search_selected_results', get_users("include={$args['selected']}"), $args); ;
710
+			$users         = array_merge($users, $selected_user);
711 711
 		}
712 712
 
713 713
 		$options = array();
714 714
 
715
-		if ( $users ) {
715
+		if ($users) {
716 716
 			$options[0] = $args['placeholder'];
717
-			foreach ( $users as $user ) {
718
-				$options[ absint( $user->ID ) ] = esc_html( $user->user_login . ' (' . $user->user_email . ')' );
717
+			foreach ($users as $user) {
718
+				$options[absint($user->ID)] = esc_html($user->user_login.' ('.$user->user_email.')');
719 719
 			}
720 720
 		} else {
721
-			$options[0] = __( 'No users found.', 'give' );
721
+			$options[0] = __('No users found.', 'give');
722 722
 		}
723 723
 
724
-		$output = $this->select( array(
724
+		$output = $this->select(array(
725 725
 			'name'             => $args['name'],
726 726
 			'selected'         => $args['selected'],
727 727
 			'id'               => $args['id'],
@@ -734,7 +734,7 @@  discard block
 block discarded – undo
734 734
 			'show_option_all'  => false,
735 735
 			'show_option_none' => false,
736 736
 			'data'             => $args['data'],
737
-		) );
737
+		));
738 738
 
739 739
 		return $output;
740 740
 
Please login to merge, or discard this patch.
uninstall.php 1 patch
Spacing   +47 added lines, -47 removed lines patch added patch discarded remove patch
@@ -10,61 +10,61 @@  discard block
 block discarded – undo
10 10
  */
11 11
 
12 12
 // Exit if accessed directly.
13
-if ( ! defined( 'WP_UNINSTALL_PLUGIN' ) ) {
13
+if ( ! defined('WP_UNINSTALL_PLUGIN')) {
14 14
 	exit;
15 15
 }
16 16
 
17 17
 // Load Give file.
18
-include_once( 'give.php' );
18
+include_once('give.php');
19 19
 
20 20
 global $wpdb, $wp_roles;
21 21
 
22 22
 
23
-if ( give_is_setting_enabled( give_get_option( 'uninstall_on_delete' ) ) ) {
23
+if (give_is_setting_enabled(give_get_option('uninstall_on_delete'))) {
24 24
 
25 25
 	// Delete All the Custom Post Types.
26
-	$give_taxonomies = array( 'form_category', 'form_tag' );
27
-	$give_post_types = array( 'give_forms', 'give_payment' );
28
-	foreach ( $give_post_types as $post_type ) {
26
+	$give_taxonomies = array('form_category', 'form_tag');
27
+	$give_post_types = array('give_forms', 'give_payment');
28
+	foreach ($give_post_types as $post_type) {
29 29
 
30
-		$give_taxonomies = array_merge( $give_taxonomies, get_object_taxonomies( $post_type ) );
31
-		$items           = get_posts( array(
30
+		$give_taxonomies = array_merge($give_taxonomies, get_object_taxonomies($post_type));
31
+		$items           = get_posts(array(
32 32
 			'post_type'   => $post_type,
33 33
 			'post_status' => 'any',
34
-			'numberposts' => - 1,
34
+			'numberposts' => -1,
35 35
 			'fields'      => 'ids',
36
-		) );
36
+		));
37 37
 
38
-		if ( $items ) {
39
-			foreach ( $items as $item ) {
40
-				wp_delete_post( $item, true );
38
+		if ($items) {
39
+			foreach ($items as $item) {
40
+				wp_delete_post($item, true);
41 41
 			}
42 42
 		}
43 43
 	}
44 44
 
45 45
 	// Delete All the Terms & Taxonomies.
46
-	foreach ( array_unique( array_filter( $give_taxonomies ) ) as $taxonomy ) {
46
+	foreach (array_unique(array_filter($give_taxonomies)) as $taxonomy) {
47 47
 
48
-		$terms = $wpdb->get_results( $wpdb->prepare( "SELECT t.*, tt.* FROM $wpdb->terms AS t INNER JOIN $wpdb->term_taxonomy AS tt ON t.term_id = tt.term_id WHERE tt.taxonomy IN ('%s') ORDER BY t.name ASC", $taxonomy ) );
48
+		$terms = $wpdb->get_results($wpdb->prepare("SELECT t.*, tt.* FROM $wpdb->terms AS t INNER JOIN $wpdb->term_taxonomy AS tt ON t.term_id = tt.term_id WHERE tt.taxonomy IN ('%s') ORDER BY t.name ASC", $taxonomy));
49 49
 
50 50
 		// Delete Terms.
51
-		if ( $terms ) {
52
-			foreach ( $terms as $term ) {
53
-				$wpdb->delete( $wpdb->term_taxonomy, array( 'term_taxonomy_id' => $term->term_taxonomy_id ) );
54
-				$wpdb->delete( $wpdb->terms, array( 'term_id' => $term->term_id ) );
51
+		if ($terms) {
52
+			foreach ($terms as $term) {
53
+				$wpdb->delete($wpdb->term_taxonomy, array('term_taxonomy_id' => $term->term_taxonomy_id));
54
+				$wpdb->delete($wpdb->terms, array('term_id' => $term->term_id));
55 55
 			}
56 56
 		}
57 57
 
58 58
 		// Delete Taxonomies.
59
-		$wpdb->delete( $wpdb->term_taxonomy, array( 'taxonomy' => $taxonomy ), array( '%s' ) );
59
+		$wpdb->delete($wpdb->term_taxonomy, array('taxonomy' => $taxonomy), array('%s'));
60 60
 	}
61 61
 
62 62
 	// Delete the Plugin Pages.
63
-	$give_created_pages = array( 'success_page', 'failure_page', 'history_page' );
64
-	foreach ( $give_created_pages as $p ) {
65
-		$page = give_get_option( $p, false );
66
-		if ( $page ) {
67
-			wp_delete_post( $page, true );
63
+	$give_created_pages = array('success_page', 'failure_page', 'history_page');
64
+	foreach ($give_created_pages as $p) {
65
+		$page = give_get_option($p, false);
66
+		if ($page) {
67
+			wp_delete_post($page, true);
68 68
 		}
69 69
 	}
70 70
 
@@ -73,28 +73,28 @@  discard block
 block discarded – undo
73 73
 	Give()->roles->remove_caps();
74 74
 
75 75
 	// Delete the Roles.
76
-	$give_roles = array( 'give_manager', 'give_accountant', 'give_worker', 'give_donor' );
77
-	foreach ( $give_roles as $role ) {
78
-		remove_role( $role );
76
+	$give_roles = array('give_manager', 'give_accountant', 'give_worker', 'give_donor');
77
+	foreach ($give_roles as $role) {
78
+		remove_role($role);
79 79
 	}
80 80
 
81 81
 	// Remove all database tables.
82
-	$wpdb->query( 'DROP TABLE IF EXISTS ' . $wpdb->prefix . 'give_donors' );
83
-	$wpdb->query( 'DROP TABLE IF EXISTS ' . $wpdb->prefix . 'give_donormeta' );
84
-	$wpdb->query( 'DROP TABLE IF EXISTS ' . $wpdb->prefix . 'give_customers' );
85
-	$wpdb->query( 'DROP TABLE IF EXISTS ' . $wpdb->prefix . 'give_customermeta' );
86
-	$wpdb->query( 'DROP TABLE IF EXISTS ' . $wpdb->prefix . 'give_paymentmeta' );
87
-	$wpdb->query( 'DROP TABLE IF EXISTS ' . $wpdb->prefix . 'give_formmeta' );
88
-	$wpdb->query( 'DROP TABLE IF EXISTS ' . $wpdb->prefix . 'give_logs' );
89
-	$wpdb->query( 'DROP TABLE IF EXISTS ' . $wpdb->prefix . 'give_logmeta' );
90
-	$wpdb->query( 'DROP TABLE IF EXISTS ' . $wpdb->prefix . 'give_sequential_ordering' );
91
-	$wpdb->query( 'DROP TABLE IF EXISTS ' . $wpdb->prefix . 'give_sessions' );
82
+	$wpdb->query('DROP TABLE IF EXISTS '.$wpdb->prefix.'give_donors');
83
+	$wpdb->query('DROP TABLE IF EXISTS '.$wpdb->prefix.'give_donormeta');
84
+	$wpdb->query('DROP TABLE IF EXISTS '.$wpdb->prefix.'give_customers');
85
+	$wpdb->query('DROP TABLE IF EXISTS '.$wpdb->prefix.'give_customermeta');
86
+	$wpdb->query('DROP TABLE IF EXISTS '.$wpdb->prefix.'give_paymentmeta');
87
+	$wpdb->query('DROP TABLE IF EXISTS '.$wpdb->prefix.'give_formmeta');
88
+	$wpdb->query('DROP TABLE IF EXISTS '.$wpdb->prefix.'give_logs');
89
+	$wpdb->query('DROP TABLE IF EXISTS '.$wpdb->prefix.'give_logmeta');
90
+	$wpdb->query('DROP TABLE IF EXISTS '.$wpdb->prefix.'give_sequential_ordering');
91
+	$wpdb->query('DROP TABLE IF EXISTS '.$wpdb->prefix.'give_sessions');
92 92
 
93 93
 	// Cleanup Cron Events.
94
-	wp_clear_scheduled_hook( 'give_daily_scheduled_events' );
95
-	wp_clear_scheduled_hook( 'give_weekly_scheduled_events' );
96
-	wp_clear_scheduled_hook( 'give_daily_cron' );
97
-	wp_clear_scheduled_hook( 'give_weekly_cron' );
94
+	wp_clear_scheduled_hook('give_daily_scheduled_events');
95
+	wp_clear_scheduled_hook('give_weekly_scheduled_events');
96
+	wp_clear_scheduled_hook('give_daily_cron');
97
+	wp_clear_scheduled_hook('give_weekly_cron');
98 98
 
99 99
 	// Get all options.
100 100
 	$give_option_names = $wpdb->get_col(
@@ -104,16 +104,16 @@  discard block
 block discarded – undo
104 104
 		)
105 105
 	);
106 106
 
107
-	if ( ! empty( $give_option_names ) ) {
107
+	if ( ! empty($give_option_names)) {
108 108
 		// Convert option name to transient or option name.
109 109
 		$new_give_option_names = array();
110 110
 
111 111
 		// Delete all the Plugin Options.
112
-		foreach ( $give_option_names as $option ) {
113
-			if ( false !== strpos( $option, 'give_cache' ) ) {
114
-				Give_Cache::delete( $option );
112
+		foreach ($give_option_names as $option) {
113
+			if (false !== strpos($option, 'give_cache')) {
114
+				Give_Cache::delete($option);
115 115
 			} else {
116
-				delete_option( $option );
116
+				delete_option($option);
117 117
 			}
118 118
 		}
119 119
 	}
Please login to merge, or discard this patch.
includes/class-give-db-payment-meta.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -10,7 +10,7 @@  discard block
 block discarded – undo
10 10
  */
11 11
 
12 12
 // Exit if accessed directly.
13
-if ( ! defined( 'ABSPATH' ) ) {
13
+if ( ! defined('ABSPATH')) {
14 14
 	exit;
15 15
 }
16 16
 
@@ -51,13 +51,13 @@  discard block
 block discarded – undo
51 51
 		global $wpdb;
52 52
 
53 53
 		// @todo: We leave $wpdb->paymentmeta for backward compatibility, use $wpdb->donationmeta instead. We can remove it after 2.1.3.
54
-		$wpdb->paymentmeta = $wpdb->donationmeta = $this->table_name = $wpdb->prefix . 'give_donationmeta';
54
+		$wpdb->paymentmeta = $wpdb->donationmeta = $this->table_name = $wpdb->prefix.'give_donationmeta';
55 55
 		$this->version     = '1.0';
56 56
 
57 57
 		// Backward compatibility.
58
-		if ( ! give_has_upgrade_completed( 'v220_rename_donation_meta_type' ) ) {
58
+		if ( ! give_has_upgrade_completed('v220_rename_donation_meta_type')) {
59 59
 			$this->meta_type = 'payment';
60
-			$wpdb->paymentmeta = $wpdb->donationmeta = $this->table_name = $wpdb->prefix . 'give_paymentmeta';
60
+			$wpdb->paymentmeta = $wpdb->donationmeta = $this->table_name = $wpdb->prefix.'give_paymentmeta';
61 61
 		}
62 62
 
63 63
 		$this->register_table();
@@ -90,6 +90,6 @@  discard block
 block discarded – undo
90 90
 	 * @return bool
91 91
 	 */
92 92
 	protected function is_custom_meta_table_active() {
93
-		return give_has_upgrade_completed( 'v20_move_metadata_into_new_table' );
93
+		return give_has_upgrade_completed('v20_move_metadata_into_new_table');
94 94
 	}
95 95
 }
Please login to merge, or discard this patch.
includes/class-notices.php 1 patch
Spacing   +112 added lines, -113 removed lines patch added patch discarded remove patch
@@ -10,7 +10,7 @@  discard block
 block discarded – undo
10 10
  */
11 11
 
12 12
 // Exit if accessed directly.
13
-if ( ! defined( 'ABSPATH' ) ) {
13
+if ( ! defined('ABSPATH')) {
14 14
 	exit;
15 15
 }
16 16
 
@@ -53,21 +53,21 @@  discard block
 block discarded – undo
53 53
 	 * @since 1.8.9
54 54
 	 */
55 55
 	public function __construct() {
56
-		add_action( 'admin_notices', array( $this, 'render_admin_notices' ), 999 );
57
-		add_action( 'give_dismiss_notices', array( $this, 'dismiss_notices' ) );
56
+		add_action('admin_notices', array($this, 'render_admin_notices'), 999);
57
+		add_action('give_dismiss_notices', array($this, 'dismiss_notices'));
58 58
 
59
-		add_action( 'give_frontend_notices', array( $this, 'render_frontend_notices' ), 999 );
60
-		add_action( 'give_pre_form_output', array( $this, 'render_frontend_form_notices' ), 10, 1 );
61
-		add_action( 'give_ajax_donation_errors', array( $this, 'render_frontend_notices' ) );
59
+		add_action('give_frontend_notices', array($this, 'render_frontend_notices'), 999);
60
+		add_action('give_pre_form_output', array($this, 'render_frontend_form_notices'), 10, 1);
61
+		add_action('give_ajax_donation_errors', array($this, 'render_frontend_notices'));
62 62
 
63 63
 		/**
64 64
 		 * Backward compatibility for deprecated params.
65 65
 		 *
66 66
 		 * @since 1.8.14
67 67
 		 */
68
-		add_filter( 'give_register_notice_args', array( $this, 'bc_deprecated_params' ) );
69
-		add_filter( 'give_frontend_errors_args', array( $this, 'bc_deprecated_params' ) );
70
-		add_filter( 'give_frontend_notice_args', array( $this, 'bc_deprecated_params' ) );
68
+		add_filter('give_register_notice_args', array($this, 'bc_deprecated_params'));
69
+		add_filter('give_frontend_errors_args', array($this, 'bc_deprecated_params'));
70
+		add_filter('give_frontend_notice_args', array($this, 'bc_deprecated_params'));
71 71
 	}
72 72
 
73 73
 	/**
@@ -80,19 +80,19 @@  discard block
 block discarded – undo
80 80
 	 *
81 81
 	 * @return array
82 82
 	 */
83
-	public function bc_deprecated_params( $args ) {
83
+	public function bc_deprecated_params($args) {
84 84
 		/**
85 85
 		 *  Param: auto_dismissible
86 86
 		 *  deprecated in 1.8.14
87 87
 		 *
88 88
 		 *  Check if auto_dismissible is set and it true then unset and change dismissible parameter value to auto
89 89
 		 */
90
-		if ( isset( $args['auto_dismissible'] ) ) {
91
-			if ( ! empty( $args['auto_dismissible'] ) ) {
90
+		if (isset($args['auto_dismissible'])) {
91
+			if ( ! empty($args['auto_dismissible'])) {
92 92
 				$args['dismissible'] = 'auto';
93 93
 			}
94 94
 			// unset auto_dismissible as it has been deprecated.
95
-			unset( $args['auto_dismissible'] );
95
+			unset($args['auto_dismissible']);
96 96
 		}
97 97
 
98 98
 		return $args;
@@ -108,9 +108,9 @@  discard block
 block discarded – undo
108 108
 	 *
109 109
 	 * @return bool
110 110
 	 */
111
-	public function register_notice( $notice_args ) {
111
+	public function register_notice($notice_args) {
112 112
 		// Bailout.
113
-		if ( empty( $notice_args['id'] ) || array_key_exists( $notice_args['id'], self::$notices ) ) {
113
+		if (empty($notice_args['id']) || array_key_exists($notice_args['id'], self::$notices)) {
114 114
 			return false;
115 115
 		}
116 116
 
@@ -159,39 +159,39 @@  discard block
 block discarded – undo
159 159
 		 *
160 160
 		 * @since 1.8.14
161 161
 		 */
162
-		$notice_args = apply_filters( 'give_register_notice_args', $notice_args );
162
+		$notice_args = apply_filters('give_register_notice_args', $notice_args);
163 163
 
164 164
 		// Set extra dismiss links if any.
165
-		if ( false !== strpos( $notice_args['description'], 'data-dismiss-interval' ) ) {
165
+		if (false !== strpos($notice_args['description'], 'data-dismiss-interval')) {
166 166
 
167
-			preg_match_all( "/data-([^\"]*)=\"([^\"]*)\"/", $notice_args['description'], $extra_notice_dismiss_link );
167
+			preg_match_all("/data-([^\"]*)=\"([^\"]*)\"/", $notice_args['description'], $extra_notice_dismiss_link);
168 168
 
169
-			if ( ! empty( $extra_notice_dismiss_link ) ) {
170
-				$extra_notice_dismiss_links = array_chunk( current( $extra_notice_dismiss_link ), 3 );
171
-				foreach ( $extra_notice_dismiss_links as $extra_notice_dismiss_link ) {
169
+			if ( ! empty($extra_notice_dismiss_link)) {
170
+				$extra_notice_dismiss_links = array_chunk(current($extra_notice_dismiss_link), 3);
171
+				foreach ($extra_notice_dismiss_links as $extra_notice_dismiss_link) {
172 172
 					// Create array og key ==> value by parsing query string created after renaming data attributes.
173
-					$data_attribute_query_str = str_replace( array( 'data-', '-', '"' ), array(
173
+					$data_attribute_query_str = str_replace(array('data-', '-', '"'), array(
174 174
 						'',
175 175
 						'_',
176 176
 						'',
177
-					), implode( '&', $extra_notice_dismiss_link ) );
177
+					), implode('&', $extra_notice_dismiss_link));
178 178
 
179
-					$notice_args['extra_links'][] = wp_parse_args( $data_attribute_query_str );
179
+					$notice_args['extra_links'][] = wp_parse_args($data_attribute_query_str);
180 180
 				}
181 181
 			}
182 182
 		}
183 183
 
184 184
 
185
-		self::$notices[ $notice_args['id'] ] = $notice_args;
185
+		self::$notices[$notice_args['id']] = $notice_args;
186 186
 
187 187
 		// Auto set show param if not already set.
188
-		if ( ! isset( self::$notices[ $notice_args['id'] ]['show'] ) ) {
189
-			self::$notices[ $notice_args['id'] ]['show'] = $this->is_notice_dismissed( $notice_args ) ? false : true;
188
+		if ( ! isset(self::$notices[$notice_args['id']]['show'])) {
189
+			self::$notices[$notice_args['id']]['show'] = $this->is_notice_dismissed($notice_args) ? false : true;
190 190
 		}
191 191
 
192 192
 		// Auto set time interval for shortly.
193
-		if ( 'shortly' === self::$notices[ $notice_args['id'] ]['dismiss_interval'] ) {
194
-			self::$notices[ $notice_args['id'] ]['dismiss_interval_time'] = DAY_IN_SECONDS;
193
+		if ('shortly' === self::$notices[$notice_args['id']]['dismiss_interval']) {
194
+			self::$notices[$notice_args['id']]['dismiss_interval_time'] = DAY_IN_SECONDS;
195 195
 		}
196 196
 
197 197
 		return true;
@@ -205,51 +205,51 @@  discard block
 block discarded – undo
205 205
 	 */
206 206
 	public function render_admin_notices() {
207 207
 		// Bailout.
208
-		if ( empty( self::$notices ) ) {
208
+		if (empty(self::$notices)) {
209 209
 			return;
210 210
 		}
211 211
 
212 212
 		$output = '';
213 213
 
214
-		foreach ( self::$notices as $notice_id => $notice ) {
214
+		foreach (self::$notices as $notice_id => $notice) {
215 215
 			// Check flag set to true to show notice.
216
-			if ( ! $notice['show'] ) {
216
+			if ( ! $notice['show']) {
217 217
 				continue;
218 218
 			}
219 219
 
220 220
 
221 221
 			// Render custom html.
222
-			if( ! empty( $notice['description_html'] ) ) {
222
+			if ( ! empty($notice['description_html'])) {
223 223
 				$output .= "{$notice['description_html']} \n";
224 224
 				continue;
225 225
 			}
226 226
 
227 227
 			// Check if notice dismissible or not.
228
-			if ( ! self::$has_auto_dismissible_notice ) {
229
-				self::$has_auto_dismissible_notice = ( 'auto' === $notice['dismissible'] );
228
+			if ( ! self::$has_auto_dismissible_notice) {
229
+				self::$has_auto_dismissible_notice = ('auto' === $notice['dismissible']);
230 230
 			}
231 231
 
232 232
 			// Check if notice dismissible or not.
233
-			if ( ! self::$has_dismiss_interval_notice ) {
233
+			if ( ! self::$has_dismiss_interval_notice) {
234 234
 				self::$has_dismiss_interval_notice = $notice['dismiss_interval'];
235 235
 			}
236 236
 
237
-			$css_id = ( false === strpos( $notice['id'], 'give' ) ? "give-{$notice['id']}" : $notice['id'] );
237
+			$css_id = (false === strpos($notice['id'], 'give') ? "give-{$notice['id']}" : $notice['id']);
238 238
 
239
-			$css_class = 'give-notice notice ' . ( empty( $notice['dismissible'] ) ? 'non' : 'is' ) . "-dismissible {$notice['type']} notice-{$notice['type']}";
240
-			$output    .= sprintf(
241
-				'<div id="%1$s" class="%2$s" data-dismissible="%3$s" data-dismissible-type="%4$s" data-dismiss-interval="%5$s" data-notice-id="%6$s" data-security="%7$s" data-dismiss-interval-time="%8$s" style="display: none">' . " \n",
239
+			$css_class = 'give-notice notice '.(empty($notice['dismissible']) ? 'non' : 'is')."-dismissible {$notice['type']} notice-{$notice['type']}";
240
+			$output .= sprintf(
241
+				'<div id="%1$s" class="%2$s" data-dismissible="%3$s" data-dismissible-type="%4$s" data-dismiss-interval="%5$s" data-notice-id="%6$s" data-security="%7$s" data-dismiss-interval-time="%8$s" style="display: none">'." \n",
242 242
 				$css_id,
243 243
 				$css_class,
244
-				give_clean( $notice['dismissible'] ),
244
+				give_clean($notice['dismissible']),
245 245
 				$notice['dismissible_type'],
246 246
 				$notice['dismiss_interval'],
247 247
 				$notice['id'],
248
-				empty( $notice['dismissible_type'] ) ? '' : wp_create_nonce( "give_edit_{$notice_id}_notice" ),
248
+				empty($notice['dismissible_type']) ? '' : wp_create_nonce("give_edit_{$notice_id}_notice"),
249 249
 				$notice['dismiss_interval_time']
250 250
 			);
251 251
 
252
-			$output .= ( 0 === strpos( $notice['description'], '<div' ) || 0 === strpos( $notice['description'], '<p' ) ? $notice['description'] : "<p>{$notice['description']}</p>" );
252
+			$output .= (0 === strpos($notice['description'], '<div') || 0 === strpos($notice['description'], '<p') ? $notice['description'] : "<p>{$notice['description']}</p>");
253 253
 			$output .= "</div> \n";
254 254
 		}
255 255
 
@@ -267,18 +267,18 @@  discard block
 block discarded – undo
267 267
 	 *
268 268
 	 * @param int $form_id
269 269
 	 */
270
-	public function render_frontend_notices( $form_id = 0 ) {
270
+	public function render_frontend_notices($form_id = 0) {
271 271
 		$errors = give_get_errors();
272 272
 
273
-		$request_form_id = isset( $_REQUEST['form-id'] ) ? absint( $_REQUEST['form-id'] ) : 0;
273
+		$request_form_id = isset($_REQUEST['form-id']) ? absint($_REQUEST['form-id']) : 0;
274 274
 
275 275
 		// Sanity checks first: Ensure that gateway returned errors display on the appropriate form.
276
-		if ( ! isset( $_POST['give_ajax'] ) && $request_form_id !== $form_id ) {
276
+		if ( ! isset($_POST['give_ajax']) && $request_form_id !== $form_id) {
277 277
 			return;
278 278
 		}
279 279
 
280
-		if ( $errors ) {
281
-			self::print_frontend_errors( $errors );
280
+		if ($errors) {
281
+			self::print_frontend_errors($errors);
282 282
 
283 283
 			give_clear_errors();
284 284
 		}
@@ -295,13 +295,13 @@  discard block
 block discarded – undo
295 295
 	 *
296 296
 	 * @return void
297 297
 	 */
298
-	public function render_frontend_form_notices( $form_id ) {
299
-		$display_option = give_get_meta( $form_id, '_give_payment_display', true );
298
+	public function render_frontend_form_notices($form_id) {
299
+		$display_option = give_get_meta($form_id, '_give_payment_display', true);
300 300
 
301
-		if ( 'modal' === $display_option ) {
302
-			add_action( 'give_payment_mode_top', array( $this, 'render_frontend_notices' ) );
301
+		if ('modal' === $display_option) {
302
+			add_action('give_payment_mode_top', array($this, 'render_frontend_notices'));
303 303
 		} else {
304
-			add_action( 'give_pre_form', array( $this, 'render_frontend_notices' ), 11 );
304
+			add_action('give_pre_form', array($this, 'render_frontend_notices'), 11);
305 305
 		}
306 306
 	}
307 307
 
@@ -312,7 +312,7 @@  discard block
 block discarded – undo
312 312
 	 * @access private
313 313
 	 */
314 314
 	private function print_js() {
315
-		if ( self::$has_auto_dismissible_notice ) :
315
+		if (self::$has_auto_dismissible_notice) :
316 316
 			?>
317 317
 			<script>
318 318
 				jQuery(document).ready(function () {
@@ -328,7 +328,7 @@  discard block
 block discarded – undo
328 328
 			<?php
329 329
 		endif;
330 330
 
331
-		if ( self::$has_dismiss_interval_notice ) :
331
+		if (self::$has_dismiss_interval_notice) :
332 332
 			?>
333 333
 			<script>
334 334
 				jQuery(document).ready(function () {
@@ -407,36 +407,36 @@  discard block
 block discarded – undo
407 407
 	 * @access public
408 408
 	 */
409 409
 	public function dismiss_notices() {
410
-		$_post     = give_clean( $_POST );
411
-		$notice_id = esc_attr( $_post['notice_id'] );
410
+		$_post     = give_clean($_POST);
411
+		$notice_id = esc_attr($_post['notice_id']);
412 412
 
413 413
 		// Bailout.
414 414
 		if (
415
-			empty( $notice_id ) ||
416
-			empty( $_post['dismissible_type'] ) ||
417
-			empty( $_post['dismiss_interval'] ) ||
418
-			! check_ajax_referer( "give_edit_{$notice_id}_notice", '_wpnonce' )
415
+			empty($notice_id) ||
416
+			empty($_post['dismissible_type']) ||
417
+			empty($_post['dismiss_interval']) ||
418
+			! check_ajax_referer("give_edit_{$notice_id}_notice", '_wpnonce')
419 419
 		) {
420 420
 			wp_send_json_error();
421 421
 		}
422 422
 
423
-		$notice_key = Give()->notices->get_notice_key( $notice_id, $_post['dismiss_interval'] );
424
-		if ( 'user' === $_post['dismissible_type'] ) {
423
+		$notice_key = Give()->notices->get_notice_key($notice_id, $_post['dismiss_interval']);
424
+		if ('user' === $_post['dismissible_type']) {
425 425
 			$current_user = wp_get_current_user();
426
-			$notice_key   = Give()->notices->get_notice_key( $notice_id, $_post['dismiss_interval'], $current_user->ID );
426
+			$notice_key   = Give()->notices->get_notice_key($notice_id, $_post['dismiss_interval'], $current_user->ID);
427 427
 		}
428 428
 
429
-		$notice_dismiss_time = ! empty( $_post['dismiss_interval_time'] ) ? $_post['dismiss_interval_time'] : null;
429
+		$notice_dismiss_time = ! empty($_post['dismiss_interval_time']) ? $_post['dismiss_interval_time'] : null;
430 430
 
431 431
 		// Save option to hide notice.
432
-		Give_Cache::set( $notice_key, true, $notice_dismiss_time, true );
432
+		Give_Cache::set($notice_key, true, $notice_dismiss_time, true);
433 433
 
434 434
 		/**
435 435
 		 * Fire the action when notice dismissed
436 436
 		 *
437 437
 		 * @since 2.2.0
438 438
 		 */
439
-		do_action( 'give_notice_dismissed', $_post );
439
+		do_action('give_notice_dismissed', $_post);
440 440
 
441 441
 		wp_send_json_success();
442 442
 	}
@@ -454,18 +454,18 @@  discard block
 block discarded – undo
454 454
 	 *
455 455
 	 * @return string
456 456
 	 */
457
-	public function get_notice_key( $notice_id, $dismiss_interval = null, $user_id = 0 ) {
457
+	public function get_notice_key($notice_id, $dismiss_interval = null, $user_id = 0) {
458 458
 		$notice_key = "_give_notice_{$notice_id}";
459 459
 
460
-		if ( ! empty( $dismiss_interval ) ) {
460
+		if ( ! empty($dismiss_interval)) {
461 461
 			$notice_key .= "_{$dismiss_interval}";
462 462
 		}
463 463
 
464
-		if ( $user_id ) {
464
+		if ($user_id) {
465 465
 			$notice_key .= "_{$user_id}";
466 466
 		}
467 467
 
468
-		$notice_key = sanitize_key( $notice_key );
468
+		$notice_key = sanitize_key($notice_key);
469 469
 
470 470
 		return $notice_key;
471 471
 	}
@@ -478,11 +478,11 @@  discard block
 block discarded – undo
478 478
 	 *
479 479
 	 * @return string
480 480
 	 */
481
-	public function get_dismiss_link( $notice_args ) {
481
+	public function get_dismiss_link($notice_args) {
482 482
 		$notice_args = wp_parse_args(
483 483
 			$notice_args,
484 484
 			array(
485
-				'title'                 => __( 'Click here', 'give' ),
485
+				'title'                 => __('Click here', 'give'),
486 486
 				'dismissible_type'      => '',
487 487
 				'dismiss_interval'      => '',
488 488
 				'dismiss_interval_time' => null,
@@ -509,31 +509,31 @@  discard block
 block discarded – undo
509 509
 	 *
510 510
 	 * @return bool|null
511 511
 	 */
512
-	public function is_notice_dismissed( $notice ) {
513
-		$notice_key          = $this->get_notice_key( $notice['id'], $notice['dismiss_interval'] );
512
+	public function is_notice_dismissed($notice) {
513
+		$notice_key          = $this->get_notice_key($notice['id'], $notice['dismiss_interval']);
514 514
 		$is_notice_dismissed = false;
515 515
 
516
-		if ( 'user' === $notice['dismissible_type'] ) {
516
+		if ('user' === $notice['dismissible_type']) {
517 517
 			$current_user = wp_get_current_user();
518
-			$notice_key   = Give()->notices->get_notice_key( $notice['id'], $notice['dismiss_interval'], $current_user->ID );
518
+			$notice_key   = Give()->notices->get_notice_key($notice['id'], $notice['dismiss_interval'], $current_user->ID);
519 519
 		}
520 520
 
521
-		$notice_data = Give_Cache::get( $notice_key, true );
521
+		$notice_data = Give_Cache::get($notice_key, true);
522 522
 
523 523
 		// Find notice dismiss link status if notice has extra dismissible links.
524
-		if ( ( empty( $notice_data ) || is_wp_error( $notice_data ) ) && ! empty( $notice['extra_links'] ) ) {
524
+		if ((empty($notice_data) || is_wp_error($notice_data)) && ! empty($notice['extra_links'])) {
525 525
 
526
-			foreach ( $notice['extra_links'] as $extra_link ) {
527
-				$new_notice_data = wp_parse_args( $extra_link, $notice );
528
-				unset( $new_notice_data['extra_links'] );
526
+			foreach ($notice['extra_links'] as $extra_link) {
527
+				$new_notice_data = wp_parse_args($extra_link, $notice);
528
+				unset($new_notice_data['extra_links']);
529 529
 
530
-				if ( $is_notice_dismissed = $this->is_notice_dismissed( $new_notice_data ) ) {
530
+				if ($is_notice_dismissed = $this->is_notice_dismissed($new_notice_data)) {
531 531
 					return $is_notice_dismissed;
532 532
 				}
533 533
 			}
534 534
 		}
535 535
 
536
-		$is_notice_dismissed = ! empty( $notice_data ) && ! is_wp_error( $notice_data );
536
+		$is_notice_dismissed = ! empty($notice_data) && ! is_wp_error($notice_data);
537 537
 
538 538
 		return $is_notice_dismissed;
539 539
 	}
@@ -547,9 +547,9 @@  discard block
 block discarded – undo
547 547
 	 *
548 548
 	 * @param array $errors
549 549
 	 */
550
-	public static function print_frontend_errors( $errors ) {
550
+	public static function print_frontend_errors($errors) {
551 551
 		// Bailout.
552
-		if ( ! $errors ) {
552
+		if ( ! $errors) {
553 553
 			return;
554 554
 		}
555 555
 
@@ -564,37 +564,37 @@  discard block
 block discarded – undo
564 564
 		);
565 565
 
566 566
 		// Note: we will remove give_errors class in future.
567
-		$classes = apply_filters( 'give_error_class', array( 'give_notices', 'give_errors' ) );
567
+		$classes = apply_filters('give_error_class', array('give_notices', 'give_errors'));
568 568
 
569
-		echo sprintf( '<div class="%s">', implode( ' ', $classes ) );
569
+		echo sprintf('<div class="%s">', implode(' ', $classes));
570 570
 
571 571
 		// Loop error codes and display errors.
572
-		foreach ( $errors as $error_id => $error ) {
572
+		foreach ($errors as $error_id => $error) {
573 573
 			// Backward compatibility v<1.8.11
574
-			if ( is_string( $error ) ) {
574
+			if (is_string($error)) {
575 575
 				$error = array(
576 576
 					'message'     => $error,
577 577
 					'notice_args' => array(),
578 578
 				);
579 579
 			}
580 580
 
581
-			$notice_args = wp_parse_args( $error['notice_args'], $default_notice_args );
581
+			$notice_args = wp_parse_args($error['notice_args'], $default_notice_args);
582 582
 
583 583
 			/**
584 584
 			 * Filter to modify Frontend Errors args before errors is display.
585 585
 			 *
586 586
 			 * @since 1.8.14
587 587
 			 */
588
-			$notice_args = apply_filters( 'give_frontend_errors_args', $notice_args );
588
+			$notice_args = apply_filters('give_frontend_errors_args', $notice_args);
589 589
 
590 590
 			echo sprintf(
591 591
 				'<div class="give_error give_notice" id="give_error_%1$s" data-dismissible="%2$s" data-dismiss-interval="%3$d">
592 592
 						<p><strong>%4$s</strong>: %5$s</p>
593 593
 					</div>',
594 594
 				$error_id,
595
-				give_clean( $notice_args['dismissible'] ),
596
-				absint( $notice_args['dismiss_interval'] ),
597
-				esc_html__( 'Error', 'give' ),
595
+				give_clean($notice_args['dismissible']),
596
+				absint($notice_args['dismiss_interval']),
597
+				esc_html__('Error', 'give'),
598 598
 				$error['message']
599 599
 			);
600 600
 		}
@@ -616,8 +616,8 @@  discard block
 block discarded – undo
616 616
 	 *
617 617
 	 * @return  string
618 618
 	 */
619
-	public static function print_frontend_notice( $message, $echo = true, $notice_type = 'warning', $notice_args = array() ) {
620
-		if ( empty( $message ) ) {
619
+	public static function print_frontend_notice($message, $echo = true, $notice_type = 'warning', $notice_args = array()) {
620
+		if (empty($message)) {
621 621
 			return '';
622 622
 		}
623 623
 
@@ -632,7 +632,7 @@  discard block
 block discarded – undo
632 632
 			'dismiss_interval' => 5000,
633 633
 		);
634 634
 
635
-		$notice_args = wp_parse_args( $notice_args, $default_notice_args );
635
+		$notice_args = wp_parse_args($notice_args, $default_notice_args);
636 636
 
637 637
 		// Notice dismissible must be true for dismiss type.
638 638
 		$notice_args['dismiss_type'] = ! $notice_args['dismissible'] ? '' : $notice_args['dismiss_type'];
@@ -642,15 +642,14 @@  discard block
 block discarded – undo
642 642
 		 *
643 643
 		 * @since 1.8.14
644 644
 		 */
645
-		$notice_args = apply_filters( 'give_frontend_notice_args', $notice_args );
645
+		$notice_args = apply_filters('give_frontend_notice_args', $notice_args);
646 646
 
647 647
 		$close_icon = 'manual' === $notice_args['dismiss_type'] ?
648 648
 			sprintf(
649 649
 				'<img class="notice-dismiss give-notice-close" src="%s" />',
650
-				esc_url( GIVE_PLUGIN_URL . 'assets/dist/images/close.svg' )
650
+				esc_url(GIVE_PLUGIN_URL.'assets/dist/images/close.svg')
651 651
 
652
-			) :
653
-			'';
652
+			) : '';
654 653
 
655 654
 		// Note: we will remove give_errors class in future.
656 655
 		$error = sprintf(
@@ -661,15 +660,15 @@  discard block
 block discarded – undo
661 660
 						%6$s
662 661
 					</div>',
663 662
 			$notice_type,
664
-			give_clean( $notice_args['dismissible'] ),
665
-			absint( $notice_args['dismiss_interval'] ),
666
-			give_clean( $notice_args['dismiss_type'] ),
663
+			give_clean($notice_args['dismissible']),
664
+			absint($notice_args['dismiss_interval']),
665
+			give_clean($notice_args['dismiss_type']),
667 666
 			$message,
668 667
 			$close_icon
669 668
 
670 669
 		);
671 670
 
672
-		if ( ! $echo ) {
671
+		if ( ! $echo) {
673 672
 			return $error;
674 673
 		}
675 674
 
@@ -689,24 +688,24 @@  discard block
 block discarded – undo
689 688
 	 *
690 689
 	 * @return string
691 690
 	 */
692
-	public function print_admin_notices( $notice_args = array() ) {
691
+	public function print_admin_notices($notice_args = array()) {
693 692
 		// Bailout.
694
-		if ( empty( $notice_args['description'] ) ) {
693
+		if (empty($notice_args['description'])) {
695 694
 			return '';
696 695
 		}
697 696
 
698
-		$defaults    = array(
697
+		$defaults = array(
699 698
 			'id'          => '',
700 699
 			'echo'        => true,
701 700
 			'notice_type' => 'warning',
702 701
 			'dismissible' => true,
703 702
 		);
704
-		$notice_args = wp_parse_args( $notice_args, $defaults );
703
+		$notice_args = wp_parse_args($notice_args, $defaults);
705 704
 
706 705
 		$output    = '';
707
-		$css_id    = ! empty( $notice_args['id'] ) ? $notice_args['id'] : uniqid( 'give-inline-notice-' );
706
+		$css_id    = ! empty($notice_args['id']) ? $notice_args['id'] : uniqid('give-inline-notice-');
708 707
 		$css_class = "notice-{$notice_args['notice_type']} give-notice notice inline";
709
-		$css_class .= ( $notice_args['dismissible'] ) ? ' is-dismissible' : '';
708
+		$css_class .= ($notice_args['dismissible']) ? ' is-dismissible' : '';
710 709
 		$output    .= sprintf(
711 710
 			'<div id="%1$s" class="%2$s"><p>%3$s</p></div>',
712 711
 			$css_id,
@@ -714,7 +713,7 @@  discard block
 block discarded – undo
714 713
 			$notice_args['description']
715 714
 		);
716 715
 
717
-		if ( ! $notice_args['echo'] ) {
716
+		if ( ! $notice_args['echo']) {
718 717
 			return $output;
719 718
 		}
720 719
 
Please login to merge, or discard this patch.