WordPress.org

Make WordPress Core

Changeset 39212


Ignore:
Timestamp:
11/13/2016 10:35:15 AM (19 months ago)
Author:
dd32
Message:

WP_HTTP: Map internal Requests hooks to WordPress actions.
This change introduces a requests-{$hook} action which can be used to hook into Requests hooks, and restores the http_api_curl action.

Props rmccue.
Fixes #37843.

Location:
trunk/src
Files:
1 added
2 edited

Legend:

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

    r38894 r39212  
    301301            'useragent' => $r['user-agent'],
    302302            'blocking' => $r['blocking'],
    303             'hooks' => new Requests_Hooks(),
     303            'hooks' => new WP_HTTP_Requests_Hooks( $url, $r ),
    304304        );
    305305
  • trunk/src/wp-settings.php

    r38961 r39212  
    209209require( ABSPATH . WPINC . '/class-wp-http-response.php' );
    210210require( ABSPATH . WPINC . '/class-wp-http-requests-response.php' );
     211require( ABSPATH . WPINC . '/class-wp-http-requests-hooks.php' );
    211212require( ABSPATH . WPINC . '/widgets.php' );
    212213require( ABSPATH . WPINC . '/class-wp-widget.php' );
Note: See TracChangeset for help on using the changeset viewer.