diff --git a/superset-frontend/src/explore/components/controls/SelectAsyncControl.jsx b/superset-frontend/src/explore/components/controls/SelectAsyncControl.jsx index 75dbbd482..8ccb81f67 100644 --- a/superset-frontend/src/explore/components/controls/SelectAsyncControl.jsx +++ b/superset-frontend/src/explore/components/controls/SelectAsyncControl.jsx @@ -60,11 +60,9 @@ const SelectAsyncControl = props => { const onSelectionChange = options => { let val; if (multi) { - val = options.map(option => option.value); - } else if (options) { - val = options.value; + val = options?.map(option => option.value) ?? null; } else { - val = null; + val = options?.value ?? null; } onChange(val); };