From aa46ad32ba53a80f391e5ed1477624b1d94065a0 Mon Sep 17 00:00:00 2001 From: Aaron Caldwell Date: Tue, 4 Feb 2020 09:52:57 -0700 Subject: [PATCH] [Maps] Set filterByMapBounds to default constant if no arg passed (#55068) * Set filterByMapBounds to default constant if no arg passed * toggle accidentally refers to props instead of state for filterByBounds. update to state * Review feedback. Remove extra filterByMapBounds Co-authored-by: Elastic Machine --- .../layers/sources/es_search_source/create_source_editor.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/x-pack/legacy/plugins/maps/public/layers/sources/es_search_source/create_source_editor.js b/x-pack/legacy/plugins/maps/public/layers/sources/es_search_source/create_source_editor.js index 69e4c09eed118..0bc98e9fee1f7 100644 --- a/x-pack/legacy/plugins/maps/public/layers/sources/es_search_source/create_source_editor.js +++ b/x-pack/legacy/plugins/maps/public/layers/sources/es_search_source/create_source_editor.js @@ -227,7 +227,7 @@ export class CreateSourceEditor extends Component { label={i18n.translate('xpack.maps.source.esSearch.extentFilterLabel', { defaultMessage: `Dynamically filter for data in the visible map area`, })} - checked={this.props.filterByMapBounds} + checked={this.state.filterByMapBounds} onChange={this.onFilterByMapBoundsChange} />