Make WordPress Core

Ticket #47397: 47397.2.patch

File 47397.2.patch, 732 bytes (added by dkarfa, 6 years ago)
  • src/wp-includes/compat.php

     
    510510        require_once ABSPATH . WPINC . '/spl-autoload-compat.php';
    511511}
    512512
    513 if ( ! function_exists( 'is_countable' ) ) {
     513if ( ( version_compare( PHP_VERSION, '7.3' ) > 0 ) && ! function_exists( 'is_countable' ) ) {
    514514        /**
    515515         * Polyfill for is_countable() function added in PHP 7.3.
    516516         *
     
    532532        }
    533533}
    534534
    535 if ( ! function_exists( 'is_iterable' ) ) {
     535if ( ( version_compare( PHP_VERSION, '7.3' ) > 0 ) && ! function_exists( 'is_iterable' ) ) {
    536536        /**
    537537         * Polyfill for is_iterable() function added in PHP 7.1.
    538538         *