From d771aff700f2c5dca642c5c47a262368690d8817 Mon Sep 17 00:00:00 2001 From: yj <1336058017@qq.com> Date: Tue, 13 Aug 2024 17:54:23 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BC=98=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/App.tsx | 36 +++++++++++++++++++----------------- 1 file changed, 19 insertions(+), 17 deletions(-) diff --git a/src/App.tsx b/src/App.tsx index 5b2f692..9b36760 100644 --- a/src/App.tsx +++ b/src/App.tsx @@ -111,23 +111,25 @@ const App: React.FC = () => { }, []) useEffect(() => { - onOtherSignalr(async (item: any) => { - switch (item.key) { - case 'Invitation': - window.electron.joinNotification({ - body: item.roomName, - name: item.InviterName, - }) - joinMeetingModalRef.current.changeModal(item) - break; - case 'ForceLogout': - message.error(item.message) - await leaveChannel(true) - toSrc('/login') - break; - } - }) - }, [navigate]) + setTimeout(() => { + onOtherSignalr(async (item: any) => { + switch (item.key) { + case 'Invitation': + window.electron.joinNotification({ + body: item.roomName, + name: item.InviterName, + }) + joinMeetingModalRef.current.changeModal(item) + break; + case 'ForceLogout': + message.error(item.message) + await leaveChannel(true) + toSrc('/login') + break; + } + }) + }, 3000); + }, []) useEffect(() => { try {