Issue Bug Closed

#80152Filelist: File can not be deleted if it was reference once

Thorben Nissen 03/06/17, 13:28 updated 04/29/17, 20:25

Description

It is not possible to delete files that had been referenced in a record, e.g. a content element. Steps to reproduce:

  1. Upload a file in the file list
  2. Add a new content element (e.g. of type “textmedia”) and add this file (and save)
  3. Delete the file (reference) from the content element (and save)
  4. Try to delete the file in the file list

The file is not removed but a warning is shown:

File not deleted
The file cannot be deleted since it is still used at the following places: [record:tt_content:15943]

I tried this with 8.6.0 and the current master. Both the same behaviour.

This happens because deleted file references are considered in the checks in the ExtendedFileUtility. Whether the sys_refindex must be updated when deleting a file reference or the deleted file reference must be ignored on the process in ExtendedFileUtility.

Reviews 1