From 8d893085a1bdbd27ad06b302e16007f3603eb1ae Mon Sep 17 00:00:00 2001 From: jeremy-croff Date: Thu, 14 Mar 2024 18:46:09 -0500 Subject: [PATCH] fix(38362): add optional chain for stopasync video ref --- src/components/VideoPlayerContexts/PlaybackContext.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/components/VideoPlayerContexts/PlaybackContext.tsx b/src/components/VideoPlayerContexts/PlaybackContext.tsx index ae33a82fd0e7..d751f861711b 100644 --- a/src/components/VideoPlayerContexts/PlaybackContext.tsx +++ b/src/components/VideoPlayerContexts/PlaybackContext.tsx @@ -19,7 +19,7 @@ function PlaybackContextProvider({children}: ChildrenProps) { }, [currentVideoPlayerRef]); const stopVideo = useCallback(() => { - currentVideoPlayerRef.current?.stopAsync(); + currentVideoPlayerRef.current?.stopAsync?.(); }, [currentVideoPlayerRef]); const playVideo = useCallback(() => {