WordPress.org

Make WordPress Core

Changeset 46218


Ignore:
Timestamp:
09/20/2019 10:22:38 PM (2 months ago)
Author:
SergeyBiryukov
Message:

Code Modernization: Remove a workaround for CURLOPT_PROTOCOLS in WP_Http_Curl::request().

The CURLOPT_PROTOCOLS constant was introduced in PHP 5.2.10, so no longer needs a workaround.

Props jrf.
See #48074.

File:
1 edited

Legend:

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

    r45932 r46218  
    144144         */
    145145        curl_setopt( $handle, CURLOPT_FOLLOWLOCATION, false );
    146         if ( defined( 'CURLOPT_PROTOCOLS' ) ) { // PHP 5.2.10 / cURL 7.19.4
    147             curl_setopt( $handle, CURLOPT_PROTOCOLS, CURLPROTO_HTTP | CURLPROTO_HTTPS );
    148         }
     146        curl_setopt( $handle, CURLOPT_PROTOCOLS, CURLPROTO_HTTP | CURLPROTO_HTTPS );
    149147
    150148        switch ( $parsed_args['method'] ) {
Note: See TracChangeset for help on using the changeset viewer.