From 3cc69c9d7852602120bb25866b498b59e696d296 Mon Sep 17 00:00:00 2001 From: Eric Bailey Date: Wed, 21 Jan 2026 21:15:08 -0600 Subject: [PATCH] Fix TODO --- src/components/moderation/ReportDialog/index.tsx | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/components/moderation/ReportDialog/index.tsx b/src/components/moderation/ReportDialog/index.tsx index 305ff36290..008b1e612e 100644 --- a/src/components/moderation/ReportDialog/index.tsx +++ b/src/components/moderation/ReportDialog/index.tsx @@ -6,6 +6,7 @@ import {useLingui} from '@lingui/react' import {wait} from '#/lib/async/wait' import {getLabelingServiceTitle} from '#/lib/moderation' +import {useCallOnce} from '#/lib/once' import {sanitizeHandle} from '#/lib/strings/handles' import {useMyLabelersQuery} from '#/state/queries/preferences' import {CharProgress} from '#/view/com/composer/char-progress/CharProgress' @@ -234,12 +235,11 @@ function Inner(props: ReportDialogProps) { } }, [_, submitReport, state, dispatch, props, setPending, setSuccess]) - // TODO once - React.useEffect(() => { + useCallOnce(() => { ax.metric('reportDialog:open', { subjectType: props.subject.type, }) - }, [ax, props.subject]) + })() return (