@@ -92,7 +92,7 @@ discard block |
||
| 92 | 92 | } else { |
| 93 | 93 | foreach ( $addons as $k => $addon ) { |
| 94 | 94 | if ( empty( $addon['excerpt'] ) && $k !== 'error' ) { |
| 95 | - unset( $addons[ $k ] ); |
|
| 95 | + unset( $addons[$k] ); |
|
| 96 | 96 | } |
| 97 | 97 | } |
| 98 | 98 | } |
@@ -193,7 +193,7 @@ discard block |
||
| 193 | 193 | |
| 194 | 194 | foreach ( $list as $k => $info ) { |
| 195 | 195 | $info['slug'] = $k; |
| 196 | - $list[ $k ] = array_merge( $defaults, $info ); |
|
| 196 | + $list[$k] = array_merge( $defaults, $info ); |
|
| 197 | 197 | } |
| 198 | 198 | return $list; |
| 199 | 199 | } |
@@ -338,16 +338,16 @@ discard block |
||
| 338 | 338 | continue; |
| 339 | 339 | } |
| 340 | 340 | |
| 341 | - $wp_plugin = isset( $wp_plugins[ $folder ] ) ? $wp_plugins[ $folder ] : array(); |
|
| 341 | + $wp_plugin = isset( $wp_plugins[$folder] ) ? $wp_plugins[$folder] : array(); |
|
| 342 | 342 | $wp_version = isset( $wp_plugin['Version'] ) ? $wp_plugin['Version'] : '1.0'; |
| 343 | 343 | |
| 344 | 344 | if ( version_compare( $wp_version, $plugin->new_version, '<' ) ) { |
| 345 | 345 | $slug = explode( '/', $folder ); |
| 346 | 346 | $plugin->slug = $slug[0]; |
| 347 | - $transient->response[ $folder ] = $plugin; |
|
| 347 | + $transient->response[$folder] = $plugin; |
|
| 348 | 348 | } |
| 349 | 349 | |
| 350 | - $transient->checked[ $folder ] = $wp_version; |
|
| 350 | + $transient->checked[$folder] = $wp_version; |
|
| 351 | 351 | |
| 352 | 352 | } |
| 353 | 353 | |
@@ -380,7 +380,7 @@ discard block |
||
| 380 | 380 | */ |
| 381 | 381 | protected static function is_installed( $plugin ) { |
| 382 | 382 | $all_plugins = self::get_plugins(); |
| 383 | - return isset( $all_plugins[ $plugin ] ); |
|
| 383 | + return isset( $all_plugins[$plugin] ); |
|
| 384 | 384 | } |
| 385 | 385 | |
| 386 | 386 | /** |
@@ -419,13 +419,13 @@ discard block |
||
| 419 | 419 | } |
| 420 | 420 | |
| 421 | 421 | $download_id = isset( $plugin['id'] ) ? $plugin['id'] : 0; |
| 422 | - if ( ! empty( $download_id ) && ! isset( $version_info[ $download_id ]['package'] ) ) { |
|
| 422 | + if ( ! empty( $download_id ) && ! isset( $version_info[$download_id]['package'] ) ) { |
|
| 423 | 423 | // if this addon is using its own license, get the update url |
| 424 | 424 | $addon_info = $api->get_api_info(); |
| 425 | 425 | |
| 426 | - $version_info[ $download_id ] = $addon_info[ $download_id ]; |
|
| 426 | + $version_info[$download_id] = $addon_info[$download_id]; |
|
| 427 | 427 | if ( isset( $addon_info['error'] ) ) { |
| 428 | - $version_info[ $download_id ]['error'] = array( |
|
| 428 | + $version_info[$download_id]['error'] = array( |
|
| 429 | 429 | 'message' => $addon_info['error']['message'], |
| 430 | 430 | 'code' => $addon_info['error']['code'], |
| 431 | 431 | ); |
@@ -524,8 +524,8 @@ discard block |
||
| 524 | 524 | return $addon; |
| 525 | 525 | } |
| 526 | 526 | } |
| 527 | - } elseif ( isset( $addons[ $download_id ] ) ) { |
|
| 528 | - $plugin = $addons[ $download_id ]; |
|
| 527 | + } elseif ( isset( $addons[$download_id] ) ) { |
|
| 528 | + $plugin = $addons[$download_id]; |
|
| 529 | 529 | } |
| 530 | 530 | |
| 531 | 531 | return $plugin; |
@@ -586,7 +586,7 @@ discard block |
||
| 586 | 586 | self::prepare_addon_link( $addon['link'] ); |
| 587 | 587 | |
| 588 | 588 | self::set_addon_status( $addon ); |
| 589 | - $addons[ $id ] = $addon; |
|
| 589 | + $addons[$id] = $addon; |
|
| 590 | 590 | } |
| 591 | 591 | } |
| 592 | 592 | |
@@ -622,7 +622,7 @@ discard block |
||
| 622 | 622 | 'utm_medium' => 'addons', |
| 623 | 623 | 'utm_campaign' => 'liteplugin', |
| 624 | 624 | ); |
| 625 | - $link = add_query_arg( $query_args, $link ); |
|
| 625 | + $link = add_query_arg( $query_args, $link ); |
|
| 626 | 626 | } |
| 627 | 627 | |
| 628 | 628 | /** |
@@ -201,8 +201,8 @@ discard block |
||
| 201 | 201 | |
| 202 | 202 | if ( is_wp_error( $resp ) ) { |
| 203 | 203 | $error_string = $resp->get_error_message(); |
| 204 | - $errors[ 'field' . $args['id'] ] = __( 'There was a problem verifying your captcha', 'formidable' ); |
|
| 205 | - $errors[ 'field' . $args['id'] ] .= ' ' . $error_string; |
|
| 204 | + $errors['field' . $args['id']] = __( 'There was a problem verifying your captcha', 'formidable' ); |
|
| 205 | + $errors['field' . $args['id']] .= ' ' . $error_string; |
|
| 206 | 206 | return $errors; |
| 207 | 207 | } |
| 208 | 208 | |
@@ -229,7 +229,7 @@ discard block |
||
| 229 | 229 | if ( $invalid_message === __( 'The reCAPTCHA was not entered correctly', 'formidable' ) ) { |
| 230 | 230 | $invalid_message = ''; |
| 231 | 231 | } |
| 232 | - $errors[ 'field' . $args['id'] ] = ( $invalid_message === '' ? $frm_settings->re_msg : $invalid_message ); |
|
| 232 | + $errors['field' . $args['id']] = ( $invalid_message === '' ? $frm_settings->re_msg : $invalid_message ); |
|
| 233 | 233 | } |
| 234 | 234 | |
| 235 | 235 | return $errors; |
@@ -245,8 +245,8 @@ discard block |
||
| 245 | 245 | $frm_vars['captcha_scores'] = array(); |
| 246 | 246 | } |
| 247 | 247 | $form_id = is_object( $this->field ) ? $this->field->form_id : $this->field['form_id']; |
| 248 | - if ( ! isset( $frm_vars['captcha_scores'][ $form_id ] ) ) { |
|
| 249 | - $frm_vars['captcha_scores'][ $form_id ] = $score; |
|
| 248 | + if ( ! isset( $frm_vars['captcha_scores'][$form_id] ) ) { |
|
| 249 | + $frm_vars['captcha_scores'][$form_id] = $score; |
|
| 250 | 250 | } |
| 251 | 251 | } |
| 252 | 252 | |
@@ -106,8 +106,8 @@ |
||
| 106 | 106 | function load_formidable_pro() { |
| 107 | 107 | } |
| 108 | 108 | /** |
| 109 | - * @return WPMailSMTP\Core |
|
| 110 | - */ |
|
| 109 | + * @return WPMailSMTP\Core |
|
| 110 | + */ |
|
| 111 | 111 | function wp_mail_smtp() { |
| 112 | 112 | } |
| 113 | 113 | /** |
@@ -26,7 +26,8 @@ |
||
| 26 | 26 | public static function toggle( $id, $name, $args ) { |
| 27 | 27 | wp_enqueue_script( 'formidable_settings' ); |
| 28 | 28 | return FrmAppHelper::clip( |
| 29 | - function() use ( $id, $name, $args ) { // @phpstan-ignore-line |
|
| 29 | + function() use ( $id, $name, $args ) { |
|
| 30 | +// @phpstan-ignore-line |
|
| 30 | 31 | require FrmAppHelper::plugin_path() . '/classes/views/shared/toggle.php'; |
| 31 | 32 | }, |
| 32 | 33 | isset( $args['echo'] ) ? $args['echo'] : false |