From 7a9ee63bd37293bbd2a14c273edaa3e6e7b75140 Mon Sep 17 00:00:00 2001 From: Josh Hawkins <32435876+hawkeye217@users.noreply.github.com> Date: Sun, 26 May 2024 18:48:33 -0500 Subject: [PATCH] save video dimensions in onLoadedData instead of onLoadedMetadata (#11545) --- web/src/components/player/MsePlayer.tsx | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/web/src/components/player/MsePlayer.tsx b/web/src/components/player/MsePlayer.tsx index 6a41a93e6..841b824db 100644 --- a/web/src/components/player/MsePlayer.tsx +++ b/web/src/components/player/MsePlayer.tsx @@ -303,8 +303,10 @@ function MSEPlayer({ className={className} playsInline preload="auto" - onLoadedData={onPlaying} - onLoadedMetadata={handleLoadedMetadata} + onLoadedData={() => { + handleLoadedMetadata?.(); + onPlaying?.(); + }} muted={!audioEnabled} onError={() => { if (wsRef.current) {