Added extra info on the PR.
attilatilman → created an issue.
MR updated with cache handling.
Added 14th point which helps make the configs form more clean.
attilatilman → changed the visibility of the branch 3446787-if-site-is to hidden.
attilatilman → created an issue.
Added an extra bullet point in https://www.drupal.org/project/acquia_dam/issues/3392227 📌 Various code quality improvements before releasing v1.1.0 stable Postponed and linked this issue in there.
attilatilman → created an issue.
attilatilman → created an issue.
Add a minor simplification.
Oops, accidentally removed one line of code which was not intentional. Updated patch uploaded.
I have came across this problem when I was working on one of my projects. I have tried on D10.1 and D11.dev, but the current patch does not solve the problem. Once the $form['relations']['parent']['#multiple'];
is set to FALSE, then the $form_state->getValue('parent');
going to return a string value on form submit. Once the form calls buildEntity()
it will throw an error because it expects and array value and uses like this: array_values($form_state->getValue('parent'));
. Since the return value is going to be a string it will fail. I have came up with a quick fix which will check if the return value is an array or not.
attilatilman → created an issue.