@haloduck/ui 2.0.19 → 2.0.20

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -728,10 +728,10 @@ class SelectComponent {
728
728
  onTouched = () => { };
729
729
  writeValue(value) {
730
730
  if (Array.isArray(value)) {
731
- this.selectedOptionIds = value;
731
+ this.selectedOptionIds = value.filter(id => id !== null && id !== undefined && id !== '');
732
732
  }
733
733
  else {
734
- this.selectedOptionIds = [value];
734
+ this.selectedOptionIds = (value !== null && value !== undefined && value !== '') ? [value] : [];
735
735
  }
736
736
  this.recomputeSelectedOptions();
737
737
  }