From be786f53e9c8386e2ff17ed562dce62506b01297 Mon Sep 17 00:00:00 2001 From: brandonocasey Date: Fri, 14 Feb 2020 15:06:48 -0500 Subject: [PATCH] fix: null check fullscreen toggle to fix ios without it --- src/plugin.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/plugin.js b/src/plugin.js index 9844f306..7a1c5f92 100644 --- a/src/plugin.js +++ b/src/plugin.js @@ -626,7 +626,7 @@ void main() { } // if ios remove full screen toggle - if (videojs.browser.IS_IOS) { + if (videojs.browser.IS_IOS && this.player_.controlBar && this.player_.controlBar.fullscreenToggle) { this.player_.controlBar.fullscreenToggle.hide(); } @@ -798,7 +798,7 @@ void main() { } // show the fullscreen again - if (videojs.browser.IS_IOS) { + if (videojs.browser.IS_IOS && this.player_.controlBar && this.player_.controlBar.fullscreenToggle) { this.player_.controlBar.fullscreenToggle.show(); }