From 81148209ddd581cfafcf2923bed89a9deda2af7b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Piotr=20Jamr=C3=B3z?= Date: Mon, 16 Aug 2021 11:11:58 +0200 Subject: [PATCH] Update docs --- public/app/plugins/datasource/graphite/state/context.tsx | 1 + public/app/plugins/datasource/graphite/state/store.ts | 2 -- 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/public/app/plugins/datasource/graphite/state/context.tsx b/public/app/plugins/datasource/graphite/state/context.tsx index 6433325f773..9fc504f075e 100644 --- a/public/app/plugins/datasource/graphite/state/context.tsx +++ b/public/app/plugins/datasource/graphite/state/context.tsx @@ -36,6 +36,7 @@ export const GraphiteQueryEditorContext = ({ }); }, []); + // synchronise changes provided in props with editor's state useEffect(() => { dispatch(actions.timeRangeChanged(range)); }, [dispatch, range]); diff --git a/public/app/plugins/datasource/graphite/state/store.ts b/public/app/plugins/datasource/graphite/state/store.ts index 394ef6a5bb5..b7dc42bcf66 100644 --- a/public/app/plugins/datasource/graphite/state/store.ts +++ b/public/app/plugins/datasource/graphite/state/store.ts @@ -168,8 +168,6 @@ const reducer = async (action: Action, state: GraphiteQueryEditorState): Promise handleTargetChanged(state); } if (actions.runQuery.match(action)) { - // handleTargetChanged() builds target from segments/tags/functions only, - // it doesn't handle refresh when target is change explicitly state.refresh(state.target.target); } if (actions.toggleEditorMode.match(action)) {