Make WordPress Core


Ignore:
Timestamp:
09/17/2015 04:46:00 AM (9 years ago)
Author:
wonderboymusic
Message:

Uploader: Fire 'wp_handle_upload' in wp_upload_bits(). Thusly, the filter in wp_xmlrpc_server::mw_newMediaObject() is redundant.

Props dllh.
Fixes #33539.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-includes/functions.php

    r34129 r34257  
    19941994    $url = $upload['url'] . "/$filename";
    19951995
    1996     return array( 'file' => $new_file, 'url' => $url, 'error' => false );
     1996    /** This filter is documented in wp-admin/includes/file.php */
     1997    return apply_filters( 'wp_handle_upload', array( 'file' => $new_file, 'url' => $url, 'type' => $wp_filetype['type'], 'error' => false ), 'sideload' );
    19971998}
    19981999
Note: See TracChangeset for help on using the changeset viewer.