New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Regression in text filter format overview submit when disabled formats exist #4419
Comments
Crazy, the fix is a one-liner... The trick is to get the same filter list (filter_formats() with same parameters) in both, function filter_admin_overview() and function filter_admin_overview_submit(). If that's not the case, disabled ones create empty formats on submission as they exist in To test the PR follow the instructions in the Issue description. |
Tested and reviewed |
Is this a duplicate of #4407? |
No, it's unrelated. There's no solution yet for the other issue. |
Thanks! Merged backdrop/backdrop#3151 into 1.x and 1.16.x. |
Description of the bug
When at least one format is disabled and the filter format overview form gets submitted (changing the weight of a format), an additional empty format gets created, causing several php notices and warnings.
Steps To Reproduce
To reproduce the behavior:
Actual behavior
You might have guessed: "aaanotherformat" is the name of the disabled one.
Additionally a new file gets created in config directory:
filter.format..json
With this content:
Additional information
This popped up while I was trying to figure out a possible solution for another (unrelated) Issue but it's reproducible on a different install.
Both have php 7.2, one is the latest dev (git).
Deleting that additional broken filter config file and enabling the filter via UI and then deleting the newly created broken filter config again "solves" the problem. At least the notices go away and no additional config files get created (as long as there's no disabled format).
The text was updated successfully, but these errors were encountered: