Changeset 46424
- Timestamp:
- 10/07/2019 07:06:41 PM (5 years ago)
- Location:
- trunk/src/wp-includes
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-includes/class-http.php
r46232 r46424 134 134 * need to be separately decompressed. Default true. 135 135 * @type bool $sslverify Whether to verify SSL for the request. Default true. 136 * @type string sslcertificatesAbsolute path to an SSL certificate .crt file.136 * @type string $sslcertificates Absolute path to an SSL certificate .crt file. 137 137 * Default ABSPATH . WPINC . '/certificates/ca-bundle.crt'. 138 138 * @type bool $stream Whether to stream to a file. If set to true and no filename was … … 216 216 $args = wp_parse_args( $args ); 217 217 218 // By default, H eadrequests do not cause redirections.218 // By default, HEAD requests do not cause redirections. 219 219 if ( isset( $args['method'] ) && 'HEAD' == $args['method'] ) { 220 220 $defaults['redirection'] = 0; … … 251 251 * @since 2.9.0 252 252 * 253 * @param false|array|WP_Error $preempt Whether to preempt an HTTP request's return value. Default false.254 * @param array $parsed_args 255 * @param string $url The request URL.253 * @param false|array|WP_Error $preempt Whether to preempt an HTTP request's return value. Default false. 254 * @param array $parsed_args HTTP request arguments. 255 * @param string $url The request URL. 256 256 */ 257 257 $pre = apply_filters( 'pre_http_request', false, $parsed_args, $url ); … … 410 410 * @since 2.8.0 411 411 * 412 * @param array|WP_Error $response HTTP response or WP_Error object.413 * @param string $context Context under which the hook is fired.414 * @param string $class HTTP transport used.415 * @param array $parsed_args 416 * @param string $url The request URL.412 * @param array|WP_Error $response HTTP response or WP_Error object. 413 * @param string $context Context under which the hook is fired. 414 * @param string $class HTTP transport used. 415 * @param array $parsed_args HTTP request arguments. 416 * @param string $url The request URL. 417 417 */ 418 418 do_action( 'http_api_debug', $response, 'response', 'Requests', $parsed_args, $url ); … … 439 439 * @since 2.9.0 440 440 * 441 * @param array $response HTTP response.442 * @param array $parsed_args 443 * @param string $url The request URL.441 * @param array $response HTTP response. 442 * @param array $parsed_args HTTP request arguments. 443 * @param string $url The request URL. 444 444 */ 445 445 return apply_filters( 'http_response', $response, $parsed_args, $url ); … … 891 891 return ! preg_match( $wildcard_regex, $check['host'] ); 892 892 } else { 893 return ! in_array( $check['host'], $accessible_hosts ); // Inverse logic, If it's in the array, then we can't accessit.893 return ! in_array( $check['host'], $accessible_hosts ); // Inverse logic, if it's in the array, then don't block it. 894 894 } 895 895 … … 990 990 991 991 /** 992 * Handles HTTP Redirects and follows themif appropriate.992 * Handles an HTTP redirect and follows it if appropriate. 993 993 * 994 994 * @since 3.7.0 -
trunk/src/wp-includes/class-wp-http-requests-response.php
r45135 r46424 60 60 * 61 61 * @since 4.6.0 62 *63 * @see \Requests_Utility_CaseInsensitiveDictionary64 62 * 65 63 * @return \Requests_Utility_CaseInsensitiveDictionary Map of header name to header value. -
trunk/src/wp-includes/http.php
r45611 r46424 155 155 156 156 /** 157 * Retrieve the raw response from the HTTP request using the GET method.157 * Performs an HTTP request using the GET method and returns its response. 158 158 * 159 159 * @since 2.7.0 … … 172 172 173 173 /** 174 * Retrieve the raw response from the HTTP request using the POST method.174 * Performs an HTTP request using the POST method and returns its response. 175 175 * 176 176 * @since 2.7.0 … … 189 189 190 190 /** 191 * Retrieve the raw response from the HTTP request using the HEAD method.191 * Performs an HTTP request using the HEAD method and returns its response. 192 192 * 193 193 * @since 2.7.0 … … 418 418 * @since 3.4.0 419 419 * 420 * @return arrayArray of origin URLs.420 * @return string[] Array of origin URLs. 421 421 */ 422 422 function get_allowed_http_origins() { … … 439 439 * @since 3.4.0 440 440 * 441 * @param array $allowed_origins { 442 * Default allowed HTTP origins. 443 * @type string Non-secure URL for admin origin. 444 * @type string Secure URL for admin origin. 445 * @type string Non-secure URL for home origin. 446 * @type string Secure URL for home origin. 441 * @param string[] $allowed_origins { 442 * Array of default allowed HTTP origins. 443 * 444 * @type string $0 Non-secure URL for admin origin. 445 * @type string $1 Secure URL for admin origin. 446 * @type string $2 Non-secure URL for home origin. 447 * @type string $3 Secure URL for home origin. 447 448 * } 448 449 */ … … 518 519 * @since 3.5.2 519 520 * 520 * @param string $url 521 * @param string $url Request URL. 521 522 * @return false|string URL or false on failure. 522 523 */ … … 573 574 * @since 3.6.0 574 575 * 575 * @param bool falseWhether HTTP request is external or not.576 * @param string $host IP of the requested host.577 * @param string $url URL of the requested host.576 * @param bool $external Whether HTTP request is external or not. 577 * @param string $host Host name of the requested URL. 578 * @param string $url Requested URL. 578 579 */ 579 580 if ( ! apply_filters( 'http_request_host_is_external', false, $host, $url ) ) { … … 716 717 * 717 718 * @param array|false $url_parts The parsed URL. Can be false if the URL failed to parse. 718 * @param int $component The specific component to retrieve. Use one of the PHP719 * predefined constants to specify which one.720 * Defaults to -1 (= return all parts as an array).719 * @param int $component The specific component to retrieve. Use one of the PHP 720 * predefined constants to specify which one. 721 * Defaults to -1 (= return all parts as an array). 721 722 * @return mixed False on parse failure; Array of URL components on success; 722 723 * When a specific component has been requested: null if the component … … 748 749 * 749 750 * @param int $constant PHP_URL_* constant. 750 * @return string| boolThe named key or false.751 * @return string|false The named key or false. 751 752 */ 752 753 function _wp_translate_php_url_constant_to_key( $constant ) { -
trunk/src/wp-includes/taxonomy.php
r46232 r46424 3306 3306 3307 3307 /** 3308 * Retrieves the taxonomy relationship to the term object id.3308 * Retrieves the cached term objects for the given object ID. 3309 3309 * 3310 3310 * Upstream functions (like get_the_terms() and is_object_in_term()) are … … 3313 3313 * 3314 3314 * @since 2.3.0 3315 * @since 4.7.0 Returns a `WP_Error` object if `get_term()` returns an error for3315 * @since 4.7.0 Returns a `WP_Error` object if there's an error with 3316 3316 * any of the matched terms. 3317 3317 * 3318 * @param int $id Term object ID .3318 * @param int $id Term object ID, for example a post, comment, or user ID. 3319 3319 * @param string $taxonomy Taxonomy name. 3320 * @return bool| array|WP_Error Array of `WP_Term` objects, if cached.3321 * False if cache is empty for `$taxonomy` and `$id`.3322 * WP_Error if get_term() returns an error object for any term.3320 * @return bool|WP_Term[]|WP_Error Array of `WP_Term` objects, if cached. 3321 * False if cache is empty for `$taxonomy` and `$id`. 3322 * WP_Error if get_term() returns an error object for any term. 3323 3323 */ 3324 3324 function get_object_term_cache( $id, $taxonomy ) {
Note: See TracChangeset
for help on using the changeset viewer.