diff --git a/modules/backend/widgets/Form.php b/modules/backend/widgets/Form.php index 7cbb8cb24..d2c1d5f38 100644 --- a/modules/backend/widgets/Form.php +++ b/modules/backend/widgets/Form.php @@ -1227,8 +1227,8 @@ public function getSaveData(): array // Exclude fields that didn't provide any value $fieldValue = $this->dataArrayGet($result, $parts, FormField::NO_SAVE_DATA); if ($fieldValue === FormField::NO_SAVE_DATA) { - if ($widget->getConfig('type') === 'taglist' && $widget->getConfig('mode') === 'relation') { - $fieldValue = []; + if ($widget->getConfig('type') === 'taglist') { + $fieldValue = in_array($widget->getConfig('mode'), ['array','relation']) ? [] : ''; } else { continue; }