Completed
Push — master ( 065b01...a7f4f0 )
by
unknown
57s queued 47s
created
stripe/models/FrmTransLitePayment.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -126,11 +126,11 @@
 block discarded – undo
126 126
 		foreach ( $payments as $payment ) {
127 127
 			list( $amount, $currency ) = FrmTransLiteAppHelper::get_amount_and_currency_from_payment( $payment );
128 128
 
129
-			if ( ! isset( $data[ $currency ] ) ) {
130
-				$data[ $currency ] = 0;
129
+			if ( ! isset( $data[$currency] ) ) {
130
+				$data[$currency] = 0;
131 131
 			}
132 132
 
133
-			$data[ $currency ] += floatval( $amount );
133
+			$data[$currency] += floatval( $amount );
134 134
 		}
135 135
 
136 136
 		return $data;
Please login to merge, or discard this patch.
classes/helpers/FrmEmailSummaryHelper.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -236,11 +236,11 @@  discard block
 block discarded – undo
236 236
 	 */
237 237
 	public static function get_last_sent_date( $type ) {
238 238
 		$options = self::get_options();
239
-		if ( empty( $options[ 'last_' . $type ] ) ) {
239
+		if ( empty( $options['last_' . $type] ) ) {
240 240
 			return false;
241 241
 		}
242 242
 
243
-		return $options[ 'last_' . $type ];
243
+		return $options['last_' . $type];
244 244
 	}
245 245
 
246 246
 	/**
@@ -252,7 +252,7 @@  discard block
 block discarded – undo
252 252
 	public static function set_last_sent_date( $type, $value = null ) {
253 253
 		$options = self::get_options();
254 254
 
255
-		$options[ 'last_' . $type ] = null === $value ? self::get_date_from_today() : '';
255
+		$options['last_' . $type] = null === $value ? self::get_date_from_today() : '';
256 256
 		self::save_options( $options );
257 257
 	}
258 258
 
Please login to merge, or discard this patch.
stripe/helpers/FrmStrpLiteConnectHelper.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -108,7 +108,7 @@  discard block
 block discarded – undo
108 108
 			'user_id'               => get_current_user_id(),
109 109
 			'frm_strp_connect_mode' => $mode,
110 110
 		);
111
-		$data            = self::post_to_connect_server( 'initialize', $additional_body );
111
+		$data = self::post_to_connect_server( 'initialize', $additional_body );
112 112
 
113 113
 		if ( is_string( $data ) ) {
114 114
 			return $data;
@@ -143,7 +143,7 @@  discard block
 block discarded – undo
143 143
 	 * @return object|string
144 144
 	 */
145 145
 	private static function post_to_connect_server( $action, $additional_body = array() ) {
146
-		$body    = array(
146
+		$body = array(
147 147
 			'frm_strp_connect_action' => $action,
148 148
 			'frm_strp_connect_mode'   => FrmStrpLiteAppHelper::active_mode(),
149 149
 		);
Please login to merge, or discard this patch.
classes/views/frm-fields/front-end/checkbox-field.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -87,6 +87,6 @@
 block discarded – undo
87 87
 
88 88
 		?></div>
89 89
 <?php
90
-		++$option_index;
90
+		++ $option_index;
91 91
 	}//end foreach
92 92
 }//end if
Please login to merge, or discard this patch.
classes/views/frm-fields/front-end/combo-field/combo-field.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -41,7 +41,7 @@  discard block
 block discarded – undo
41 41
 			$sub_field_class   = "frm_form_field form-field frm_form_subfield-{$name} {$sub_field['wrapper_classes']}";
42 42
 			$sub_field_desc    = FrmField::get_option( $field, $name . '_desc' );
43 43
 
44
-			if ( isset( $errors[ 'field' . $field_id . '-' . $name ] ) ) {
44
+			if ( isset( $errors['field' . $field_id . '-' . $name] ) ) {
45 45
 				$sub_field_class .= ' frm_blank_field';
46 46
 			}
47 47
 			?>
@@ -61,10 +61,10 @@  discard block
 block discarded – undo
61 61
 						<input
62 62
 							type="<?php echo esc_attr( $sub_field['type'] ); ?>"
63 63
 							id="<?php echo esc_attr( $html_id . '_' . $name ); ?>"
64
-							value="<?php echo esc_attr( isset( $field_value[ $name ] ) ? $field_value[ $name ] : '' ); ?>"
64
+							value="<?php echo esc_attr( isset( $field_value[$name] ) ? $field_value[$name] : '' ); ?>"
65 65
 							<?php
66
-							if ( ! empty( $field_value[ $name ] ) ) {
67
-								echo 'data-frmval="' . esc_attr( $field_value[ $name ] ) . '" ';
66
+							if ( ! empty( $field_value[$name] ) ) {
67
+								echo 'data-frmval="' . esc_attr( $field_value[$name] ) . '" ';
68 68
 							}
69 69
 							if ( empty( $args['remove_names'] ) ) {
70 70
 								echo 'name="' . esc_attr( $field_name ) . '[' . esc_attr( $name ) . ']" ';
@@ -81,9 +81,9 @@  discard block
 block discarded – undo
81 81
 				}
82 82
 
83 83
 				// Don't show individual field errors when there is a combo field error.
84
-				if ( ! empty( $errors ) && isset( $errors[ 'field' . $field_id . '-' . $name ] ) && ! isset( $errors[ 'field' . $field_id ] ) ) {
84
+				if ( ! empty( $errors ) && isset( $errors['field' . $field_id . '-' . $name] ) && ! isset( $errors['field' . $field_id] ) ) {
85 85
 					?>
86
-					<div class="frm_error" role="alert"><?php echo esc_html( $errors[ 'field' . $field_id . '-' . $name ] ); ?></div>
86
+					<div class="frm_error" role="alert"><?php echo esc_html( $errors['field' . $field_id . '-' . $name] ); ?></div>
87 87
 				<?php } ?>
88 88
 			</div>
89 89
 			<?php
Please login to merge, or discard this patch.
classes/controllers/FrmSettingsController.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -158,7 +158,7 @@  discard block
 block discarded – undo
158 158
 				$section['function'] = $original;
159 159
 			}
160 160
 
161
-			$sections[ $key ] = $section;
161
+			$sections[$key] = $section;
162 162
 		}//end foreach
163 163
 
164 164
 		return $sections;
@@ -170,11 +170,11 @@  discard block
 block discarded – undo
170 170
 
171 171
 		$section  = FrmAppHelper::get_post_param( 'tab', '', 'sanitize_text_field' );
172 172
 		$sections = self::get_settings_tabs();
173
-		if ( ! isset( $sections[ $section ] ) ) {
173
+		if ( ! isset( $sections[$section] ) ) {
174 174
 			wp_die();
175 175
 		}
176 176
 
177
-		$section = $sections[ $section ];
177
+		$section = $sections[$section];
178 178
 
179 179
 		if ( isset( $section['class'] ) ) {
180 180
 			call_user_func( array( $section['class'], $section['function'] ) );
Please login to merge, or discard this patch.
classes/models/FrmEntryValidate.php 2 patches
Braces   +2 added lines, -1 removed lines patch added patch discarded remove patch
@@ -145,7 +145,8 @@
 block discarded – undo
145 145
 
146 146
 		if ( $posted_field->required == '1' && FrmAppHelper::is_empty_value( $value ) ) {
147 147
 			$errors[ 'field' . $args['id'] ] = FrmFieldsHelper::get_error_msg( $posted_field, 'blank' );
148
-		} elseif ( ! isset( $_POST['item_name'] ) ) { // phpcs:ignore WordPress.Security.NonceVerification.Missing
148
+		} elseif ( ! isset( $_POST['item_name'] ) ) {
149
+// phpcs:ignore WordPress.Security.NonceVerification.Missing
149 150
 			self::maybe_add_item_name( $value, $posted_field );
150 151
 		}
151 152
 
Please login to merge, or discard this patch.
Spacing   +32 added lines, -32 removed lines patch added patch discarded remove patch
@@ -27,7 +27,7 @@  discard block
 block discarded – undo
27 27
 			return $errors;
28 28
 		}
29 29
 
30
-		if ( FrmAppHelper::is_admin() && is_user_logged_in() && ( ! isset( $values[ 'frm_submit_entry_' . $values['form_id'] ] ) || ! wp_verify_nonce( $values[ 'frm_submit_entry_' . $values['form_id'] ], 'frm_submit_entry_nonce' ) ) ) {
30
+		if ( FrmAppHelper::is_admin() && is_user_logged_in() && ( ! isset( $values['frm_submit_entry_' . $values['form_id']] ) || ! wp_verify_nonce( $values['frm_submit_entry_' . $values['form_id']], 'frm_submit_entry_nonce' ) ) ) {
31 31
 			$frm_settings   = FrmAppHelper::get_settings();
32 32
 			$errors['form'] = $frm_settings->admin_permission;
33 33
 		}
@@ -130,7 +130,7 @@  discard block
 block discarded – undo
130 130
 		$args = wp_parse_args( $args, $defaults );
131 131
 
132 132
 		if ( empty( $args['parent_field_id'] ) ) {
133
-			$value = isset( $values['item_meta'][ $args['id'] ] ) ? $values['item_meta'][ $args['id'] ] : '';
133
+			$value = isset( $values['item_meta'][$args['id']] ) ? $values['item_meta'][$args['id']] : '';
134 134
 		} else {
135 135
 			// value is from a nested form
136 136
 			$value = $values;
@@ -151,7 +151,7 @@  discard block
 block discarded – undo
151 151
 		}
152 152
 
153 153
 		if ( $posted_field->required == '1' && FrmAppHelper::is_empty_value( $value ) ) {
154
-			$errors[ 'field' . $args['id'] ] = FrmFieldsHelper::get_error_msg( $posted_field, 'blank' );
154
+			$errors['field' . $args['id']] = FrmFieldsHelper::get_error_msg( $posted_field, 'blank' );
155 155
 		} elseif ( ! isset( $_POST['item_name'] ) ) { // phpcs:ignore WordPress.Security.NonceVerification.Missing
156 156
 			self::maybe_add_item_name( $value, $posted_field );
157 157
 		}
@@ -204,7 +204,7 @@  discard block
 block discarded – undo
204 204
 		$option_is_valid = (bool) apply_filters( 'frm_option_is_valid', $option_is_valid, $value, $posted_field );
205 205
 
206 206
 		if ( ! $option_is_valid ) {
207
-			$errors[ 'field' . $args['id'] ] = FrmFieldsHelper::get_error_msg( $posted_field, 'invalid' );
207
+			$errors['field' . $args['id']] = FrmFieldsHelper::get_error_msg( $posted_field, 'invalid' );
208 208
 		}
209 209
 	}
210 210
 
@@ -267,7 +267,7 @@  discard block
 block discarded – undo
267 267
 		$values['value'] = $value;
268 268
 		FrmFieldsHelper::prepare_new_front_field( $values, $field_object );
269 269
 
270
-		$map_callback = function ( $option ) {
270
+		$map_callback = function( $option ) {
271 271
 			return is_array( $option ) ? $option['value'] : $option;
272 272
 		};
273 273
 
@@ -335,7 +335,7 @@  discard block
 block discarded – undo
335 335
 			$pattern = self::phone_format( $field );
336 336
 
337 337
 			if ( ! preg_match( $pattern, $value ) ) {
338
-				$errors[ 'field' . $args['id'] ] = FrmFieldsHelper::get_error_msg( $field, 'invalid' );
338
+				$errors['field' . $args['id']] = FrmFieldsHelper::get_error_msg( $field, 'invalid' );
339 339
 			}
340 340
 		}
341 341
 	}
@@ -448,7 +448,7 @@  discard block
 block discarded – undo
448 448
 	 */
449 449
 	private static function form_is_in_progress( $values ) {
450 450
 		return FrmAppHelper::pro_is_installed() &&
451
-			( isset( $values[ 'frm_page_order_' . $values['form_id'] ] ) || FrmAppHelper::get_post_param( 'frm_next_page' ) ) &&
451
+			( isset( $values['frm_page_order_' . $values['form_id']] ) || FrmAppHelper::get_post_param( 'frm_next_page' ) ) &&
452 452
 			FrmField::get_all_types_in_form( $values['form_id'], 'break' );
453 453
 	}
454 454
 
@@ -694,9 +694,9 @@  discard block
 block discarded – undo
694 694
 			foreach ( $datas['missing_keys'] as $key_index => $key ) {
695 695
 				$found = self::is_akismet_guest_info_value( $key, $value, $field_id, $datas['name_field_ids'], $values );
696 696
 				if ( $found ) {
697
-					$datas[ $key ]             = $value;
697
+					$datas[$key]             = $value;
698 698
 					$datas['frm_duplicated'][] = $field_id;
699
-					unset( $datas['missing_keys'][ $key_index ] );
699
+					unset( $datas['missing_keys'][$key_index] );
700 700
 				}
701 701
 			}
702 702
 		}//end foreach
@@ -739,11 +739,11 @@  discard block
 block discarded – undo
739 739
 					if ( 'Name' !== $field->name ) {
740 740
 						continue;
741 741
 					}
742
-					if ( isset( $fields[ $index + 1 ] ) && 'Last' === $fields[ $index + 1 ]->name ) {
743
-						if ( empty( $values[ absint( $fields[ $index + 1 ]->id ) ] ) ) {
742
+					if ( isset( $fields[$index + 1] ) && 'Last' === $fields[$index + 1]->name ) {
743
+						if ( empty( $values[absint( $fields[$index + 1]->id )] ) ) {
744 744
 							continue;
745 745
 						}
746
-						$value .= ' ' . $values[ $fields[ $index + 1 ]->id ];
746
+						$value .= ' ' . $values[$fields[$index + 1]->id];
747 747
 						return true;
748 748
 					}
749 749
 				}
@@ -762,13 +762,13 @@  discard block
 block discarded – undo
762 762
 	 */
763 763
 	private static function get_name_text_fields( $form_id ) {
764 764
 		$name_text_fields_is_initialized = is_array( self::$name_text_fields );
765
-		if ( $name_text_fields_is_initialized && isset( self::$name_text_fields[ $form_id ] ) ) {
766
-			return self::$name_text_fields[ $form_id ];
765
+		if ( $name_text_fields_is_initialized && isset( self::$name_text_fields[$form_id] ) ) {
766
+			return self::$name_text_fields[$form_id];
767 767
 		}
768 768
 		if ( ! $name_text_fields_is_initialized ) {
769 769
 			self::$name_text_fields = array();
770 770
 		}
771
-		self::$name_text_fields[ $form_id ] = FrmDb::get_results(
771
+		self::$name_text_fields[$form_id] = FrmDb::get_results(
772 772
 			'frm_fields',
773 773
 			array(
774 774
 				'form_id' => $form_id,
@@ -779,7 +779,7 @@  discard block
 block discarded – undo
779 779
 			array( 'order_by' => 'field_order ASC' )
780 780
 		);
781 781
 
782
-		return self::$name_text_fields[ $form_id ];
782
+		return self::$name_text_fields[$form_id];
783 783
 	}
784 784
 
785 785
 	private static function add_server_values_to_akismet( &$datas ) {
@@ -788,7 +788,7 @@  discard block
 block discarded – undo
788 788
 
789 789
 			// Send any potentially useful $_SERVER vars, but avoid sending junk we don't need.
790 790
 			if ( $include_value ) {
791
-				$datas[ $key ] = $value;
791
+				$datas[$key] = $value;
792 792
 			}
793 793
 			unset( $key, $value );
794 794
 		}
@@ -805,10 +805,10 @@  discard block
 block discarded – undo
805 805
 	private static function add_comment_content_to_akismet( &$datas, $values ) {
806 806
 		if ( isset( $datas['frm_duplicated'] ) ) {
807 807
 			foreach ( $datas['frm_duplicated'] as $index ) {
808
-				if ( isset( $values['item_meta'][ $index ] ) ) {
809
-					unset( $values['item_meta'][ $index ] );
808
+				if ( isset( $values['item_meta'][$index] ) ) {
809
+					unset( $values['item_meta'][$index] );
810 810
 				} else {
811
-					unset( $values[ $index ] );
811
+					unset( $values[$index] );
812 812
 				}
813 813
 			}
814 814
 			unset( $datas['frm_duplicated'] );
@@ -827,14 +827,14 @@  discard block
 block discarded – undo
827 827
 	private static function skip_adding_values_to_akismet( &$values ) {
828 828
 		$skipped_fields = self::get_akismet_skipped_field_ids( $values );
829 829
 		foreach ( $skipped_fields as $skipped_field ) {
830
-			if ( ! isset( $values['item_meta'][ $skipped_field->id ] ) ) {
830
+			if ( ! isset( $values['item_meta'][$skipped_field->id] ) ) {
831 831
 				continue;
832 832
 			}
833 833
 
834 834
 			if ( self::should_really_skip_field( $skipped_field, $values ) ) {
835
-				unset( $values['item_meta'][ $skipped_field->id ] );
836
-				if ( isset( $values['item_meta']['other'][ $skipped_field->id ] ) ) {
837
-					unset( $values['item_meta']['other'][ $skipped_field->id ] );
835
+				unset( $values['item_meta'][$skipped_field->id] );
836
+				if ( isset( $values['item_meta']['other'][$skipped_field->id] ) ) {
837
+					unset( $values['item_meta']['other'][$skipped_field->id] );
838 838
 				}
839 839
 			}
840 840
 		}
@@ -870,14 +870,14 @@  discard block
 block discarded – undo
870 870
 		}
871 871
 
872 872
 		// If a choice field has Other option, but Other is not selected.
873
-		if ( empty( $values['item_meta']['other'][ $field_data->id ] ) ) {
873
+		if ( empty( $values['item_meta']['other'][$field_data->id] ) ) {
874 874
 			return true;
875 875
 		}
876 876
 
877 877
 		// Check if submitted value is same as one of field option.
878 878
 		foreach ( $field_data->options as $option ) {
879 879
 			$option_value = ! is_array( $option ) ? $option : ( isset( $option['value'] ) ? $option['value'] : '' );
880
-			if ( $values['item_meta']['other'][ $field_data->id ] === $option_value ) {
880
+			if ( $values['item_meta']['other'][$field_data->id] === $option_value ) {
881 881
 				return true;
882 882
 			}
883 883
 		}
@@ -948,7 +948,7 @@  discard block
 block discarded – undo
948 948
 
949 949
 			// Convert name array to string.
950 950
 			if ( isset( $value['first'] ) && isset( $value['last'] ) ) {
951
-				$values['item_meta'][ $field_id ] = trim( implode( ' ', $value ) );
951
+				$values['item_meta'][$field_id] = trim( implode( ' ', $value ) );
952 952
 				$values['name_field_ids'][]       = $field_id;
953 953
 				continue;
954 954
 			}
@@ -969,8 +969,8 @@  discard block
 block discarded – undo
969 969
 						continue;
970 970
 					}
971 971
 
972
-					if ( ! isset( $values['item_meta'][ $subsubindex ] ) ) {
973
-						$values['item_meta'][ $subsubindex ] = array();
972
+					if ( ! isset( $values['item_meta'][$subsubindex] ) ) {
973
+						$values['item_meta'][$subsubindex] = array();
974 974
 					}
975 975
 
976 976
 					// Convert name array to string.
@@ -980,13 +980,13 @@  discard block
 block discarded – undo
980 980
 						$values['name_field_ids'][] = $subsubindex;
981 981
 					}
982 982
 
983
-					if ( is_array( $values['item_meta'][ $subsubindex ] ) ) {
984
-						$values['item_meta'][ $subsubindex ][] = $subsubvalue;
983
+					if ( is_array( $values['item_meta'][$subsubindex] ) ) {
984
+						$values['item_meta'][$subsubindex][] = $subsubvalue;
985 985
 					}
986 986
 				}
987 987
 			}//end foreach
988 988
 
989
-			unset( $values['item_meta'][ $field_id ] );
989
+			unset( $values['item_meta'][$field_id] );
990 990
 		}//end foreach
991 991
 
992 992
 		return $form_ids;
Please login to merge, or discard this patch.
classes/models/FrmAddon.php 2 patches
Braces   +2 added lines, -1 removed lines patch added patch discarded remove patch
@@ -465,7 +465,8 @@
 block discarded – undo
465 465
 	}
466 466
 
467 467
 	private function is_license_revoked() {
468
-		if ( empty( $this->license ) || empty( $this->plugin_slug ) || isset( $_POST['license'] ) ) { // phpcs:ignore WordPress.Security.NonceVerification.Missing
468
+		if ( empty( $this->license ) || empty( $this->plugin_slug ) || isset( $_POST['license'] ) ) {
469
+// phpcs:ignore WordPress.Security.NonceVerification.Missing
469 470
 			return;
470 471
 		}
471 472
 
Please login to merge, or discard this patch.
Spacing   +15 added lines, -15 removed lines patch added patch discarded remove patch
@@ -70,7 +70,7 @@  discard block
 block discarded – undo
70 70
 	}
71 71
 
72 72
 	public function insert_installed_addon( $plugins ) {
73
-		$plugins[ $this->plugin_slug ] = $this;
73
+		$plugins[$this->plugin_slug] = $this;
74 74
 
75 75
 		return $plugins;
76 76
 	}
@@ -78,8 +78,8 @@  discard block
 block discarded – undo
78 78
 	public static function get_addon( $plugin_slug ) {
79 79
 		$plugins = apply_filters( 'frm_installed_addons', array() );
80 80
 		$plugin  = false;
81
-		if ( isset( $plugins[ $plugin_slug ] ) ) {
82
-			$plugin = $plugins[ $plugin_slug ];
81
+		if ( isset( $plugins[$plugin_slug] ) ) {
82
+			$plugin = $plugins[$plugin_slug];
83 83
 		}
84 84
 
85 85
 		return $plugin;
@@ -139,7 +139,7 @@  discard block
 block discarded – undo
139 139
 		} else {
140 140
 			$api     = new FrmFormApi( $this->license );
141 141
 			$plugins = $api->get_api_info();
142
-			$_data   = $plugins[ $item_id ];
142
+			$_data   = $plugins[$item_id];
143 143
 		}
144 144
 
145 145
 		$_data['sections'] = array(
@@ -380,19 +380,19 @@  discard block
 block discarded – undo
380 380
 
381 381
 		if ( $this->is_current_version( $transient ) ) {
382 382
 			// Make sure it doesn't show there is an update if plugin is up-to-date.
383
-			if ( isset( $transient->response[ $this->plugin_folder ] ) ) {
384
-				unset( $transient->response[ $this->plugin_folder ] );
383
+			if ( isset( $transient->response[$this->plugin_folder] ) ) {
384
+				unset( $transient->response[$this->plugin_folder] );
385 385
 			}
386
-		} elseif ( isset( $transient->response ) && isset( $transient->response[ $this->plugin_folder ] ) ) {
387
-			$this->prepare_update_details( $transient->response[ $this->plugin_folder ] );
386
+		} elseif ( isset( $transient->response ) && isset( $transient->response[$this->plugin_folder] ) ) {
387
+			$this->prepare_update_details( $transient->response[$this->plugin_folder] );
388 388
 
389 389
 			// if the transient has expired, clear the update and trigger it again
390
-			if ( $transient->response[ $this->plugin_folder ] === false ) {
390
+			if ( $transient->response[$this->plugin_folder] === false ) {
391 391
 				if ( ! $this->has_been_cleared() ) {
392 392
 					$this->cleared_plugins();
393 393
 					$this->manually_queue_update();
394 394
 				}
395
-				unset( $transient->response[ $this->plugin_folder ] );
395
+				unset( $transient->response[$this->plugin_folder] );
396 396
 			}
397 397
 		}
398 398
 
@@ -482,7 +482,7 @@  discard block
 block discarded – undo
482 482
 	}
483 483
 
484 484
 	private function is_current_version( $transient ) {
485
-		if ( empty( $transient->checked ) || ! isset( $transient->checked[ $this->plugin_folder ] ) ) {
485
+		if ( empty( $transient->checked ) || ! isset( $transient->checked[$this->plugin_folder] ) ) {
486 486
 			return false;
487 487
 		}
488 488
 
@@ -491,7 +491,7 @@  discard block
 block discarded – undo
491 491
 			return true;
492 492
 		}
493 493
 
494
-		return isset( $transient->response ) && isset( $transient->response[ $this->plugin_folder ] ) && $transient->checked[ $this->plugin_folder ] === $transient->response[ $this->plugin_folder ]->new_version;
494
+		return isset( $transient->response ) && isset( $transient->response[$this->plugin_folder] ) && $transient->checked[$this->plugin_folder] === $transient->response[$this->plugin_folder]->new_version;
495 495
 	}
496 496
 
497 497
 	/**
@@ -633,8 +633,8 @@  discard block
 block discarded – undo
633 633
 			$response['message'] = $response['status'];
634 634
 		} else {
635 635
 			$messages = $this->get_messages();
636
-			if ( is_string( $response['status'] ) && isset( $messages[ $response['status'] ] ) ) {
637
-				$response['message'] = $messages[ $response['status'] ];
636
+			if ( is_string( $response['status'] ) && isset( $messages[$response['status']] ) ) {
637
+				$response['message'] = $messages[$response['status']];
638 638
 			} else {
639 639
 				$response['message'] = FrmAppHelper::kses( $response['status'], array( 'a' ) );
640 640
 			}
@@ -796,7 +796,7 @@  discard block
 block discarded – undo
796 796
 			'user-agent' => $this->plugin_slug . '/' . $this->version . '; ' . get_bloginfo( 'url' ),
797 797
 		);
798 798
 
799
-		$resp              = wp_remote_post(
799
+		$resp = wp_remote_post(
800 800
 			$this->store_url . '?l=' . urlencode( base64_encode( $this->license ) ),
801 801
 			$arg_array
802 802
 		);
Please login to merge, or discard this patch.
stripe/controllers/FrmStrpLiteActionsController.php 1 patch
Spacing   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -47,7 +47,7 @@  discard block
 block discarded – undo
47 47
 			$gateway   = $payment_action->post_content['gateway'];
48 48
 			$is_stripe = $gateway === 'stripe' || ( is_array( $gateway ) && in_array( 'stripe', $gateway, true ) );
49 49
 			if ( ! $is_stripe || empty( $payment_action->post_content['amount'] ) ) {
50
-				unset( $payment_actions[ $k ] );
50
+				unset( $payment_actions[$k] );
51 51
 			}
52 52
 		}
53 53
 		return $payment_actions;
@@ -84,7 +84,7 @@  discard block
 block discarded – undo
84 84
 			'run_triggers' => false,
85 85
 			'show_errors'  => true,
86 86
 		);
87
-		$atts     = compact( 'action', 'entry', 'form' );
87
+		$atts = compact( 'action', 'entry', 'form' );
88 88
 
89 89
 		$amount = self::prepare_amount( $action->post_content['amount'], $atts );
90 90
 		if ( empty( $amount ) || $amount == 000 ) {
@@ -502,7 +502,7 @@  discard block
 block discarded – undo
502 502
 		$disallowed = array( ';', ':', '!important' );
503 503
 		foreach ( $settings as $k => $s ) {
504 504
 			if ( is_string( $s ) ) {
505
-				$settings[ $k ] = str_replace( $disallowed, '', $s );
505
+				$settings[$k] = str_replace( $disallowed, '', $s );
506 506
 			}
507 507
 		}
508 508
 
@@ -574,18 +574,18 @@  discard block
 block discarded – undo
574 574
 	 * @return array
575 575
 	 */
576 576
 	public static function remove_cc_validation( $errors, $field, $values ) {
577
-		$has_processed = isset( $_POST[ 'frmintent' . $field->form_id ] ); // phpcs:ignore WordPress.Security.NonceVerification.Missing
577
+		$has_processed = isset( $_POST['frmintent' . $field->form_id] ); // phpcs:ignore WordPress.Security.NonceVerification.Missing
578 578
 		if ( ! $has_processed ) {
579 579
 			return $errors;
580 580
 		}
581 581
 
582 582
 		$field_id = isset( $field->temp_id ) ? $field->temp_id : $field->id;
583 583
 
584
-		if ( isset( $errors[ 'field' . $field_id . '-cc' ] ) ) {
585
-			unset( $errors[ 'field' . $field_id . '-cc' ] );
584
+		if ( isset( $errors['field' . $field_id . '-cc'] ) ) {
585
+			unset( $errors['field' . $field_id . '-cc'] );
586 586
 		}
587
-		if ( isset( $errors[ 'field' . $field_id ] ) ) {
588
-			unset( $errors[ 'field' . $field_id ] );
587
+		if ( isset( $errors['field' . $field_id] ) ) {
588
+			unset( $errors['field' . $field_id] );
589 589
 		}
590 590
 
591 591
 		return $errors;
Please login to merge, or discard this patch.