Enforce array for subform values#16733
Conversation
|
I have tested this item ✅ successfully on fb04de3 This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/16733. |
1 similar comment
|
I have tested this item ✅ successfully on fb04de3 This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/16733. |
|
Did you get here an object produced in core or by an extension? Because there should never arrive here an object if all is working as it should. If there is code in core which passes an object, then the bug is probably on that edge. |
|
Hi @laoneo is there any subform in the core? |
|
Yes the list based custom fields. |
|
Sorry offtopic: #15723 I thought Custom Fields don´t support subforms. But true - the listfield is one. But why does this work but custom CustomFields not? |
|
@laoneo could you please evaluate your thoughts? |
|
I have tested this item ✅ successfully on fb04de3 This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/16733. |
|
I have tested this item ✅ successfully on fb04de3 This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/16733. |
|
RTC after two successful tests. |
|
I just fear that it can have unexpected behaviors if an object is passed. @bembelimen where and how do you pass the object, perhaps I do miss something here. |
|
@bembelimen any feedback on Allon's last comment? |
|
I'm not sure, what I should answer here? The object is passed via $form->bind($data); The question is: what should break here, because the field expect an array... |
* staging: (148 commits) Correcting non-escaped double quotes in en-GB.plg_sampledata_testing.ini (joomla#17455) Correct namespace reference (Fix joomla#17448) Correcting Jalali/Persian calendar popup (joomla#17432) Adding russian calendar language file (joomla#17443) Reset for dev Prepare 3.8 Beta release Fix covers tags Fix file paths Move library files to just libraries/src as it should be (joomla#17441) Add a default empty array for the session queue (joomla#16943) [3.8] Restructure version constants (joomla#16169) Adjusting copyright and versions and two remaining "sampledata" (joomla#17435) PHP 7.2 has branched, update Travis config to reflect PHP 7.2 count warning (joomla#16840) Enforce array for subform values (joomla#16733) System URL menu link (joomla#17419) Don't use array merge here. (joomla#17391) add the checked attribute (joomla#17336) [RFC] Mod sample data (joomla#7680) Rename Page to Menu Item (joomla#17409) ...
* staging: (148 commits) Correcting non-escaped double quotes in en-GB.plg_sampledata_testing.ini (joomla#17455) Correct namespace reference (Fix joomla#17448) Correcting Jalali/Persian calendar popup (joomla#17432) Adding russian calendar language file (joomla#17443) Reset for dev Prepare 3.8 Beta release Fix covers tags Fix file paths Move library files to just libraries/src as it should be (joomla#17441) Add a default empty array for the session queue (joomla#16943) [3.8] Restructure version constants (joomla#16169) Adjusting copyright and versions and two remaining "sampledata" (joomla#17435) PHP 7.2 has branched, update Travis config to reflect PHP 7.2 count warning (joomla#16840) Enforce array for subform values (joomla#16733) System URL menu link (joomla#17419) Don't use array merge here. (joomla#17391) add the checked attribute (joomla#17336) [RFC] Mod sample data (joomla#7680) Rename Page to Menu Item (joomla#17409) ...
Summary of Changes
This PR enforce, that the value is an array, because I had the case, that I get an object and the field stopped working.
Testing Instructions
Apply the patch, it should work like before.