Skip to content

Commit

Permalink
Remove submitted values from data if field is disabled (#25682)
Browse files Browse the repository at this point in the history
  • Loading branch information
degobbis authored and HLeithner committed Jul 30, 2019
1 parent 45e4304 commit 7faa14f
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions plugins/system/fields/fields.php
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,13 @@ public function onContentNormaliseRequestData($context, $data, Form $form)
* they should NEVER be added by the browser anyway so nothing to check against
* as "disabled" means no interaction at all.
*/

// Make sure the data object has an entry before delete it
if (isset($data->com_fields[$field->fieldname]))
{
unset($data->com_fields[$field->fieldname]);
}

continue;
}

Expand Down

0 comments on commit 7faa14f

Please sign in to comment.