Skip to content

[5.x]: Asset Transforms Are Not Removed When An Asset is Replaced #15753

Open

Description

What happened?

Description

We replaced an image asset using the asset manager but all entries that use the asset are still displaying the old image. This is because Craft is not deleting old images transforms. I've tried all cache clearing mechanisms and Craft will not delete old image transforms. Only manual deletion is successful.

Steps to reproduce

  1. Add an image asset to a matrix
  2. Create an entry using the matrix
  3. Use twig function tag to create an image tag and pass a transform via twig as well
  4. Upload an image
  5. Replace the previous image with a new image through the asset manager

Expected behavior

Craft should be deleting old images transforms when an asset is replaced, or when template caches are cleared

Actual behavior

The old image persists

Craft CMS version

5.3.6

PHP version

8.2

Operating system and version

No response

Database type and version

No response

Image driver and version

No response

Installed plugins and versions

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions