WordPress.org

Make WordPress Core

Ticket #12824: 12824.001.diff

File 12824.001.diff, 619 bytes (added by aaroncampbell, 5 years ago)
  • wp-includes/functions.php

     
    22092209                $name = ''; 
    22102210 
    22112211        // Increment the file number until we have a unique file to save in $dir. Use $override['unique_filename_callback'] if supplied. 
    2212         if ( $unique_filename_callback && function_exists( $unique_filename_callback ) ) { 
     2212        if ( $unique_filename_callback && is_callable( $unique_filename_callback ) ) { 
    22132213                $filename = $unique_filename_callback( $dir, $name ); 
    22142214        } else { 
    22152215                $number = '';