Problem/Motivation

When a DAM media entity is deleted from the Drupal site, the "thumbnail" file remains on the Drupal filesystem.

Steps to reproduce

  1. Add a media item from the DAM
  2. Use /admin/content/files to identify the asset file and thumbnail file
  3. Go to /admin/content/media and delete the media item
  4. Correct behavior: The asset file will be deleted
  5. Bug: The thumbnail file will remain (correct behavior: should be deleted)

Issue fork acquia_dam-3559107

Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

becw created an issue. See original summary.

becw’s picture

Status: Active » Needs review
rajeshreeputra’s picture

@becw - can we add test coverage if possible?

rajeshreeputra’s picture

Added logic to remove even the empty parent directory as well.

  • rajeshreeputra committed 9f6d7130 on 1.1.x authored by becw
    Resolve #3559107"Delete thumbnail file when media is deleted along with...
rajeshreeputra’s picture

Version: 1.1.7 » 1.1.x-dev
Status: Needs review » Fixed

MR merged!

Now that this issue is closed, review the contribution record.

As a contributor, attribute any organization that helped you, or if you volunteered your own time.

Maintainers, credit people who helped resolve this issue.

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.