Skip to content

Add an uninstall Interface to run custom module code #2160

@valadas

Description

@valadas

Description

Some modules create content that is not removable with just an sql script. For instance a media gallery module could create a folder on the filesystem to hold the various images sizes caches, it may also export large files, or templates that are useless without the module being on the site.

Current result

Currently, the IUpgradeable interface allows for a module developer to run custom code on module installation. For when the module is uninstalled, the only thing a developer can run is an uninstall sql script.

Expected result

Developers could have an IUninstallable interface that they could implement in a similar way to the IUpgradeable interface. But this new interface should also pass wether the user ticked "Delete Files" on the uninstall screen.
image

Affected version

  • 9.2
  • 9.1.1
  • 9.1
  • 9.0
    All versions, this never existed.

Affected browser

All (Not browser related)

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions