From 39bddd4cbbf7b71430cd81dfede10bb2ec490065 Mon Sep 17 00:00:00 2001 From: Lucas Fialho Zawacki Date: Wed, 29 Sep 2021 19:45:01 +0000 Subject: [PATCH] fix(vimeo): Prevent problem when calling vimeo's player getPlaybackRate --- .../imports/ui/components/external-video-player/component.jsx | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/bigbluebutton-html5/imports/ui/components/external-video-player/component.jsx b/bigbluebutton-html5/imports/ui/components/external-video-player/component.jsx index 946a9a0508..0840a33d24 100644 --- a/bigbluebutton-html5/imports/ui/components/external-video-player/component.jsx +++ b/bigbluebutton-html5/imports/ui/components/external-video-player/component.jsx @@ -312,8 +312,9 @@ class VideoPlayer extends Component { getCurrentPlaybackRate() { const intPlayer = this.player && this.player.getInternalPlayer(); + const rate = (intPlayer && intPlayer.getPlaybackRate && intPlayer.getPlaybackRate()); - return (intPlayer && intPlayer.getPlaybackRate && intPlayer.getPlaybackRate()) || 1; + return typeof(rate) == 'number' ? rate : 1; } setPlaybackRate(rate) {