WordPress.org

Make WordPress Core

Changeset 52315


Ignore:
Timestamp:
12/03/2021 06:02:40 PM (7 weeks ago)
Author:
hellofromTonya
Message:

HTTP API: Fix classname WpOrg\Requests\Proxy\Http in WP_Http::request().

Renaming the classname was missed in [52244] when updating changes in WP_Http::request() for the Requests 2.0.0 external library upgrade. HTTP class no longer exists and caused a fatal error Fatal error: Uncaught Error: Class 'WpOrg\Requests\Proxy\HTTP' not found.

This commit renames the class to Http and resolves the fatal error.

Follow-up to [52244].

Props alexeydemidov, costdev, mukesh27.
Fixes #54562.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-includes/class-wp-http.php

    r52244 r52315  
    379379        $proxy = new WP_HTTP_Proxy();
    380380        if ( $proxy->is_enabled() && $proxy->send_through_proxy( $url ) ) {
    381             $options['proxy'] = new WpOrg\Requests\Proxy\HTTP( $proxy->host() . ':' . $proxy->port() );
     381            $options['proxy'] = new WpOrg\Requests\Proxy\Http( $proxy->host() . ':' . $proxy->port() );
    382382
    383383            if ( $proxy->use_authentication() ) {
Note: See TracChangeset for help on using the changeset viewer.