Do not add dismissableblock to a block's settings if it is not using it yet

Created on 4 March 2024, 9 months ago

Problem/Motivation

On saving a block that is not (and likely won't ever) be configured to be able to be dismissed, the Dismissable Block module still adds itself as a dependency and puts an empty array into the third-party settings:

 dependencies:
   module:
     - collapsiblock
+    - dismissableblocks
     - search
     - system
   theme:
     - greenhouse
 third_party_settings:
+  dismissableblocks: {  }
   collapsiblock:
     collapse_action: 0

I believe the kids say something about that noise.

Steps to reproduce

Save a block you do not configure to be dismissable, and export your configuration.

Proposed resolution

Check, maybe in form validation, for the default / empty value and remove it before the form is saved?

Remaining tasks

User interface changes

API changes

Data model changes

πŸ“Œ Task
Status

Active

Version

1.0

Component

Code

Created by

πŸ‡ΊπŸ‡ΈUnited States mlncn Minneapolis, MN, USA

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Production build 0.71.5 2024