Make WordPress Core


Ignore:
Timestamp:
10/08/2020 09:13:57 PM (4 years ago)
Author:
SergeyBiryukov
Message:

General: Replace older-style PHP type conversion functions with type casts.

This improves performance, readability, and consistency throughout core.

  • intval()(int)
  • strval()(string)
  • floatval()(float)

Props ayeshrajans.
Fixes #42918.

File:
1 edited

Legend:

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

    r48586 r49108  
    174174
    175175        if ( isset( $parsed_args['limit_response_size'] ) ) {
    176             $this->max_body_length = intval( $parsed_args['limit_response_size'] );
     176            $this->max_body_length = (int) $parsed_args['limit_response_size'];
    177177        } else {
    178178            $this->max_body_length = false;
Note: See TracChangeset for help on using the changeset viewer.