Changeset 7225 for sites/trunk/wordpress.org/public_html/wp-content/themes/pub/wporg-main/inc/privacy-functions.php
- Timestamp:
- 05/24/2018 10:40:29 AM (6 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
sites/trunk/wordpress.org/public_html/wp-content/themes/pub/wporg-main/inc/privacy-functions.php
r7218 r7225 23 23 // Currently only enabled for special accounts. 24 24 if ( ! is_user_logged_in() || ! wporg_user_has_restricted_password() ) { 25 $api_request = new \WP_Error( 26 'not_available', 27 'This form is currently disabled.' 28 ); 25 $error_message = 'This form is currently unavailable.'; 29 26 } else 27 30 28 if ( ! reCAPTCHA\check_status() ) { 31 $error_message = 'Your form session has expired. Please try again.';29 $error_message = esc_html__( 'Your form session has expired. Please try again.', 'wporg' ); 32 30 } elseif ( 33 31 is_user_logged_in() && 34 32 ! wp_verify_nonce( $_POST['_wpnonce'], $nonce_action ) 35 33 ) { 36 $error_message = 'Your form session has expired. Please try again.';34 $error_message = esc_html__( 'Your form session has expired. Please try again.', 'wporg' ); 37 35 38 36 } elseif ( … … 43 41 if ( is_user_logged_in() ) { 44 42 $error_message = sprintf( 45 'The provided email address belongs to a different WordPress.org account. Please <a href="%1$s">log out</a> and <a href="%2$s">login to the account first</a>.',46 wp_logout_url( get_permalink()),47 wp_log in_url( get_permalink() )43 /* translators: %s: link to the Login form */ 44 __( 'The provided email address belongs to a different WordPress.org account. Please <a href="%s">login to the account first</a>.', 'wporg' ), 45 wp_logout_url( wp_login_url( get_permalink() ) ) 48 46 ); 49 47 } else { 50 48 $error_message = sprintf( 51 'The provided email address belongs to a WordPress.org account. Please <a href="%s">login to the account first</a>.', 49 /* translators: %s: link to the Login form */ 50 __( 'The provided email address belongs to a WordPress.org account. Please <a href="%s">login to the account first</a>.', 'wporg' ), 52 51 wp_login_url( get_permalink() ) 53 52 ); … … 76 75 if ( 'duplicate_request' == $api_request->get_error_code() ) { 77 76 // TODO This should never have to be displayed to an end user. See API for details. 78 $error_message = 'A request for this email address already exists. Please check your spam folder for your confirmation email.';77 $error_message = esc_html__( 'A request for this email address already exists. Please check your spam folder for your confirmation email.', 'wporg' ); 79 78 80 79 } elseif ( 'invalid_identifier' == $api_request->get_error_code() ) { 81 $error_message = 'The provided email was invalid. Please check the address and try again.';80 $error_message = esc_html__( 'The provided email was invalid. Please check the address and try again.', 'wporg' ); 82 81 83 82 }
Note: See TracChangeset
for help on using the changeset viewer.