function file_entity_file_delete in D7 Media 7
Implements hook_file_delete().
File
- file_entity/
file_entity.module, line 213 - Extends Drupal file entities to be fieldable and viewable.
Code
function file_entity_file_delete($file) {
field_attach_delete('file', $file);
// Delete image dimensions from the {image_dimensions} table
db_query('DELETE FROM {image_dimensions} WHERE fid = :fid', array(
':fid' => $file->fid,
));
}