Problem/Motivation

When uninstalling this module, it deletes any blocks which have the module's config present (even if it is empty).

Steps to reproduce

  1. Install the module
  2. Create a block and set a "not node type" or "not taxonomy type" condition and save
  3. Edit an existing block, don't change any conditions and save (thus adding config)
  4. Uninstall the module

Proposed resolution

Take inspiration from the "Block Visibility Groups" module (#2880373) and remove the conditions on the blocks on uninstall so the blocks don't get deleted.

Remaining tasks

Add uninstall functions to Block Visibility Conditions module and Block Visibility Conditions Commerce submodule.

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

littlepixiez created an issue. See original summary.

littlepixiez’s picture

Added .install files to delete the conditions to prevent the blocks being deleted.

littlepixiez’s picture

Status: Active » Needs review
mistrae’s picture

Status: Needs review » Reviewed & tested by the community

Works fine thank you

matthiasm11 made their first commit to this issue’s fork.

matthiasm11’s picture

Status: Reviewed & tested by the community » Fixed

Thank you for your work!
This has been merged and released in version 2.0.0.

Status: Fixed » Closed (fixed)

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