WordPress.org

Make WordPress Core

Ticket #12493: 12493.2.patch

File 12493.2.patch, 471 bytes (added by Viper007Bond, 12 years ago)

Pass the filename so it can be used to determine file type

  • wp-includes/functions.php

     
    22822282        if ( ! $ifp )
    22832283                return array( 'error' => sprintf( __( 'Could not write file %s' ), $new_file ) );
    22842284
     2285        $bits = apply_filters( 'wp_upload_bits_data', $bits, $new_file );
     2286
    22852287        @fwrite( $ifp, $bits );
    22862288        fclose( $ifp );
    22872289        // Set correct file permissions