mirror of
https://github.com/apache/superset.git
synced 2026-05-12 19:35:17 +00:00
[fix] handle null value in date filter (#11655)
This commit is contained in:
@@ -236,11 +236,11 @@ class DateFilterControl extends React.Component {
|
||||
};
|
||||
|
||||
const { value } = props;
|
||||
if (value.indexOf(SEPARATOR) >= 0) {
|
||||
if (value && value.indexOf(SEPARATOR) >= 0) {
|
||||
this.state = { ...this.state, ...getStateFromSeparator(value) };
|
||||
} else if (COMMON_TIME_FRAMES.indexOf(value) >= 0) {
|
||||
this.state = { ...this.state, ...getStateFromCommonTimeFrame(value) };
|
||||
} else {
|
||||
} else if (value) {
|
||||
this.state = { ...this.state, ...getStateFromCustomRange(value) };
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user