Changeset 6445

Show
Ignore:
Timestamp:
12/21/07 01:40:00 (8 months ago)
Author:
ryan
Message:

Check attachment link when deleting.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • branches/2.3/wp-app.php

    r6125 r6445  
    495495 
    496496        $location = get_post_meta($entry['ID'], '_wp_attached_file', true); 
     497        $filetype = wp_check_filetype($location); 
     498 
     499        if(!isset($location) || 'attachment' != $entry['post_type'] || empty($filetype['ext'])) 
     500            $this->internal_error(__('Error ocurred while accessing post metadata for file location.')); 
    497501 
    498502        // delete file