diff --git a/wp-includes/comment.php b/wp-includes/comment.php
index 0fb9f01093..f098910ea5 100644
--- a/wp-includes/comment.php
+++ b/wp-includes/comment.php
@@ -3065,7 +3065,7 @@ function wp_handle_comment_submission( $comment_data ) {
$comment_type = '';
if ( get_option( 'require_name_email' ) && ! $user->exists() ) {
- if ( 6 > strlen( $comment_author_email ) || '' == $comment_author ) {
+ if ( '' == $comment_author_email || '' == $comment_author ) {
return new WP_Error( 'require_name_email', __( 'ERROR: please fill the required fields (name, email).' ), 200 );
} elseif ( ! is_email( $comment_author_email ) ) {
return new WP_Error( 'require_valid_email', __( 'ERROR: please enter a valid email address.' ), 200 );
diff --git a/wp-includes/formatting.php b/wp-includes/formatting.php
index 3216363156..b8049c2064 100644
--- a/wp-includes/formatting.php
+++ b/wp-includes/formatting.php
@@ -2872,7 +2872,7 @@ function is_email( $email, $deprecated = false ) {
_deprecated_argument( __FUNCTION__, '3.0.0' );
// Test for the minimum length the email can be
- if ( strlen( $email ) < 3 ) {
+ if ( strlen( $email ) < 6 ) {
/**
* Filters whether an email address is valid.
*
@@ -3109,7 +3109,7 @@ function iso8601_to_datetime( $date_string, $timezone = 'user' ) {
*/
function sanitize_email( $email ) {
// Test for the minimum length the email can be
- if ( strlen( $email ) < 3 ) {
+ if ( strlen( $email ) < 6 ) {
/**
* Filters a sanitized email address.
*
diff --git a/wp-includes/rest-api.php b/wp-includes/rest-api.php
index ec7c50d27b..57e4e9f6fd 100644
--- a/wp-includes/rest-api.php
+++ b/wp-includes/rest-api.php
@@ -1077,11 +1077,7 @@ function rest_validate_value_from_schema( $value, $args, $param = '' ) {
break;
case 'email' :
- // is_email() checks for 3 characters (a@b), but
- // wp_handle_comment_submission() requires 6 characters (a@b.co)
- //
- // https://core.trac.wordpress.org/ticket/38506
- if ( ! is_email( $value ) || strlen( $value ) < 6 ) {
+ if ( ! is_email( $value ) ) {
return new WP_Error( 'rest_invalid_email', __( 'Invalid email address.' ) );
}
break;
diff --git a/wp-includes/version.php b/wp-includes/version.php
index d5912d513c..af70253ce4 100644
--- a/wp-includes/version.php
+++ b/wp-includes/version.php
@@ -4,7 +4,7 @@
*
* @global string $wp_version
*/
-$wp_version = '4.8-beta1-40666';
+$wp_version = '4.8-beta1-40667';
/**
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.