WordPress.org

Make WordPress Core

Changeset 5054


Ignore:
Timestamp:
03/16/07 22:12:15 (7 years ago)
Author:
ryan
Message:

Improve error propagation from newMediaObject failure in xmlrpc.php. Props Daniel Jalkut (Red Sweater Software). fixes #3981 for 2.2

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/xmlrpc.php

    r5008 r5054  
    14191419        $upload = wp_upload_bits($name, $type, $bits, $overwrite); 
    14201420        if ( ! empty($upload['error']) ) { 
    1421             logIO('O', '(MW) Could not write file '.$name); 
    1422             return new IXR_Error(500, 'Could not write file '.$name); 
     1421            $errorString = 'Could not write file ' . $name . ' (' . $upload['error'] . ')'; 
     1422            logIO('O', '(MW) ' . $errorString); 
     1423            return new IXR_Error(500, $errorString); 
    14231424        } 
    14241425        // Construct the attachment array 
Note: See TracChangeset for help on using the changeset viewer.