From 7e7355b0de1e93318b7606a9365b4f2aa77b8a6c Mon Sep 17 00:00:00 2001 From: "Jason M. Hasperhoven" Date: Fri, 23 Aug 2024 18:32:40 +0400 Subject: [PATCH] Fix typo --- apps/extension/src/hooks/popup-ready.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/apps/extension/src/hooks/popup-ready.ts b/apps/extension/src/hooks/popup-ready.ts index f385f0c9..ebcca4c4 100644 --- a/apps/extension/src/hooks/popup-ready.ts +++ b/apps/extension/src/hooks/popup-ready.ts @@ -5,13 +5,13 @@ type IsReady = boolean | undefined; // signals that react is ready (mounted) to service worker export const usePopupReady = (isReady: IsReady = undefined) => { - const sentMessagedRef = useRef(new Set()); + const sentMessagesRef = useRef(new Set()); const searchParams = new URLSearchParams(window.location.search); const popupId = searchParams.get('popupId'); useEffect(() => { - if (popupId && (isReady === undefined || isReady) && !sentMessagedRef.current.has(popupId)) { - sentMessagedRef.current.add(popupId); + if (popupId && (isReady === undefined || isReady) && !sentMessagesRef.current.has(popupId)) { + sentMessagesRef.current.add(popupId); void chrome.runtime.sendMessage({ type: PopupType.Ready,