diff --git a/wp-includes/class-http.php b/wp-includes/class-http.php index ee08e424c..b5075cc32 100644 --- a/wp-includes/class-http.php +++ b/wp-includes/class-http.php @@ -240,6 +240,9 @@ class WP_Http { $arrURL = parse_url($url); + if ( empty( $url ) || empty($url['scheme'] ) ) + return new WP_Error('http_request_failed', __('A valid URL was not provided.')); + if ( $this->block_request( $url ) ) return new WP_Error('http_request_failed', __('User has blocked requests through HTTP.'));