From 935654d5def4259a1e3ddc97a31d2511787b0c87 Mon Sep 17 00:00:00 2001 From: BGV <26331505+bgv2@users.noreply.github.com> Date: Sun, 30 Mar 2025 10:27:31 -0400 Subject: [PATCH] fix call duration --- React/src/app/call/page.tsx | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/React/src/app/call/page.tsx b/React/src/app/call/page.tsx index 5ee8795..4dff98d 100644 --- a/React/src/app/call/page.tsx +++ b/React/src/app/call/page.tsx @@ -11,15 +11,15 @@ function CallPage() { const mediaRecorderRef = useRef(null); // Reference for the MediaRecorder instance const audioChunks = useRef([]); // Array to store audio data chunks - /* - React.useEffect(() => { - const interval = setInterval(() => { - setCallDuration((prev) => prev + 1); - }, 1000); - return () => clearInterval(interval); - }, []); - */ + React.useEffect(() => { + const interval = setInterval(() => { + setCallDuration((prev) => prev + 1); + }, 1000); + + return () => clearInterval(interval); + }, []); + // Start recording const startRecording = async () => {