Skip to content

Commit 0ed8dcd

Browse files
HTTP API: Deprecate the http_api_transports filter.
The filter is only used within the `WP_Http::_get_first_available_transport()` method, which has been marked as deprecated in favor of `\WpOrg\Requests\Requests::get_transport_class()`. Follow-up to [56655] Props desrosj, hellofromTonya. Fixes #58705. git-svn-id: https://develop.svn.wordpress.org/trunk@56723 602fd350-edb4-49c9-b593-d223f7449a82
1 parent 166e042 commit 0ed8dcd

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/wp-includes/class-wp-http.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -531,13 +531,14 @@ public function _get_first_available_transport( $args, $url = null ) {
531531
* Filters which HTTP transports are available and in what order.
532532
*
533533
* @since 3.7.0
534+
* @deprecated 6.4.0 Use WpOrg\Requests\Requests::get_transport_class()
534535
*
535536
* @param string[] $transports Array of HTTP transports to check. Default array contains
536537
* 'curl' and 'streams', in that order.
537538
* @param array $args HTTP request arguments.
538539
* @param string $url The URL to request.
539540
*/
540-
$request_order = apply_filters( 'http_api_transports', $transports, $args, $url );
541+
$request_order = apply_filters_deprecated( 'http_api_transports', array( $transports, $args, $url ), '6.4.0' );
541542

542543
// Loop over each transport on each HTTP request looking for one which will serve this request's needs.
543544
foreach ( $request_order as $transport ) {

0 commit comments

Comments
 (0)