Skip to content

🎥 Make videos programmatically with React

print if premounted and buffering

Jonny Burger3c980c9ff5e7
diff --git a/packages/core/src/use-media-playback.ts b/packages/core/src/use-media-playback.ts
index 20cdf42bed..c4ed84c938 100644
--- a/packages/core/src/use-media-playback.ts
+++ b/packages/core/src/use-media-playback.ts
@@ -177,7 +177,7 @@ export const useMediaPlayback = ({
mediaRef: mediaRef.current,
time: shouldBeTime,
logLevel,
- why: `because time shift is too big. shouldBeTime = ${shouldBeTime}, isTime = ${mediaTagTime}, requestVideoCallbackTime = ${rvcTime}, timeShift = ${timeShift}, isVariableFpsVideo = ${Boolean(isVariableFpsVideo)}`,
+ why: `because time shift is too big. shouldBeTime = ${shouldBeTime}, isTime = ${mediaTagTime}, requestVideoCallbackTime = ${rvcTime}, timeShift = ${timeShift}${isVariableFpsVideo ? ', isVariableFpsVideo = true' : ''}, isPremounting = ${isPremounting}, pauseWhenBuffering = ${pauseWhenBuffering}`,
});
lastSeekDueToShift.current = lastSeek.current;
if (playing && !isVariableFpsVideo) {
@@ -265,5 +265,7 @@ export const useMediaPlayback = ({
playing,
src,
onAutoPlayError,
+ isPremounting,
+ pauseWhenBuffering,
]);
};