Skip to content

Commit 52ca5a3

Browse files
committed
feat: code cleanup
1 parent 9be9ba4 commit 52ca5a3

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed

frontend/src/container/GridCardLayout/GridCard/FullView/index.tsx

+1-1
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ function FullView({
6464

6565
useEffect(() => {
6666
setCurrentGraphRef(fullViewRef);
67-
}, [fullViewRef, setCurrentGraphRef]);
67+
}, [setCurrentGraphRef]);
6868

6969
const { selectedDashboard, isDashboardLocked } = useDashboard();
7070

frontend/src/container/GridCardLayout/GridCard/WidgetGraphComponent.tsx

+1-1
Original file line numberDiff line numberDiff line change
@@ -244,7 +244,7 @@ function WidgetGraphComponent({
244244

245245
const graphClick = useGraphClickToShowButton({
246246
graphRef: currentGraphRef?.current ? currentGraphRef : graphRef,
247-
isButtonEnabled: widget?.query?.builder?.queryData.some(
247+
isButtonEnabled: (widget?.query?.builder?.queryData ?? []).some(
248248
(q) =>
249249
q.dataSource === DataSource.TRACES || q.dataSource === DataSource.LOGS,
250250
),

frontend/src/container/NewWidget/LeftContainer/WidgetGraph/WidgetGraphs.tsx

+1-1
Original file line numberDiff line numberDiff line change
@@ -97,7 +97,7 @@ function WidgetGraph({
9797
// context redirection to explorer pages
9898
const graphClick = useGraphClickToShowButton({
9999
graphRef,
100-
isButtonEnabled: selectedWidget?.query?.builder?.queryData.some(
100+
isButtonEnabled: (selectedWidget?.query?.builder?.queryData ?? []).some(
101101
(q) =>
102102
q.dataSource === DataSource.TRACES || q.dataSource === DataSource.LOGS,
103103
),

0 commit comments

Comments
 (0)