I have a configuration that harvests a particular filefield and stores the files on s3.
If the user deletes a node, the file entries do not get deleted from the 'files' database table.
The attached patch to mm_s3_delete_file() fixes the problem.
function mm_s3_delete_file($item, $configuration) {
// Delete file entry in in 'files' table
$fid = $item['fid'];
db_query('DELETE FROM {files} WHERE fid = "%d"', $fid); // delete entry in 'files' table
...
}
| Comment | File | Size | Author |
|---|---|---|---|
| mm_s3.bug19.diff | 184 bytes | kobnim |