Make WordPress Core

Changeset 52961


Ignore:
Timestamp:
03/20/2022 03:41:48 PM (2 years ago)
Author:
SergeyBiryukov
Message:

Coding Standards: Rename the $requestPath variable to $request_path in WP_Http_Streams::request().

This fixes a Variable "$requestPath" is not in valid snake_case format WPCS warning.

Follow-up to [8516], [51825], [51929], [51940], [52960].

Props azouamauriac.
See #54728.

File:
1 edited

Legend:

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

    r52960 r52961  
    207207
    208208        if ( $proxy->is_enabled() && $proxy->send_through_proxy( $url ) ) { // Some proxies require full URL in this field.
    209             $requestPath = $url;
     209            $request_path = $url;
    210210        } else {
    211             $requestPath = $parsed_url['path'] . ( isset( $parsed_url['query'] ) ? '?' . $parsed_url['query'] : '' );
    212         }
    213 
    214         $strHeaders = strtoupper( $parsed_args['method'] ) . ' ' . $requestPath . ' HTTP/' . $parsed_args['httpversion'] . "\r\n";
     211            $request_path = $parsed_url['path'] . ( isset( $parsed_url['query'] ) ? '?' . $parsed_url['query'] : '' );
     212        }
     213
     214        $strHeaders = strtoupper( $parsed_args['method'] ) . ' ' . $request_path . ' HTTP/' . $parsed_args['httpversion'] . "\r\n";
    215215
    216216        $include_port_in_host_header = (
Note: See TracChangeset for help on using the changeset viewer.