WordPress.org

Make WordPress Core

Ticket #44532: patch.diff

File patch.diff, 652 bytes (added by itowhid06, 17 months ago)
  • src/wp-includes/functions.php

    diff --git a/src/wp-includes/functions.php b/src/wp-includes/functions.php
    index 8ae58299d6..a201b40d02 100644
    a b function _device_can_upload() { 
    55535553 * @return bool True if the path is a stream URL.
    55545554 */
    55555555function wp_is_stream( $path ) {
     5556        $path = wp_normalize_path( $path );
     5557        if ( false !== strpos( $path, 'file://' ) || false === strpos( $path, '://' ) ) {
     5558                // can't possibly be a stream
     5559                return false;
     5560        }
    55565561        $wrappers    = stream_get_wrappers();
    55575562        $wrappers    = array_map( 'preg_quote', $wrappers );
    55585563        $wrappers_re = '(' . join( '|', $wrappers ) . ')';