From 7e8dcdb11dc5dfefcdd19ff5e13ec9d8b5c24dcc Mon Sep 17 00:00:00 2001 From: Jimmy Liu Date: Fri, 2 Dec 2022 02:16:54 +0000 Subject: [PATCH] Fix muted false -> true not being set --- packages/rrweb/src/replay/index.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/packages/rrweb/src/replay/index.ts b/packages/rrweb/src/replay/index.ts index 7c94456c4f..ca38798632 100644 --- a/packages/rrweb/src/replay/index.ts +++ b/packages/rrweb/src/replay/index.ts @@ -1216,13 +1216,13 @@ export class Replayer { } const mediaEl = target as HTMLMediaElement | RRMediaElement; try { - if (d.currentTime) { + if (d.currentTime !== undefined) { mediaEl.currentTime = d.currentTime; } - if (d.volume) { + if (d.volume !== undefined) { mediaEl.volume = d.volume; } - if (d.muted) { + if (d.muted !== undefined) { mediaEl.muted = d.muted; } if (d.type === MediaInteractions.Pause) {