From 61ce88b2f52cfa079595c89a3a6a39b1c055dc6c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C3=81lvaro=20Velad=20Galv=C3=A1n?= Date: Wed, 8 May 2024 16:09:49 +0200 Subject: [PATCH] fix: Issue with compiler minifying webOS device properties (#6558) Fixes https://github.com/shaka-project/shaka-player/issues/6533 The original author is: @stuartflanagan The original PR is: https://github.com/shaka-project/shaka-player/pull/6554 --- lib/util/platform.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/util/platform.js b/lib/util/platform.js index d9bc9de3e2..b8be771659 100644 --- a/lib/util/platform.js +++ b/lib/util/platform.js @@ -684,8 +684,8 @@ shaka.util.Platform = class { /** @type {{screenWidth: number, screenHeight: number}} */( JSON.parse(window.PalmSystem.deviceInfo)); // WebOS has always been able to do 1080p. Assume a 1080p limit. - maxResolution.width = Math.max(1920, deviceInfo.screenWidth); - maxResolution.height = Math.max(1080, deviceInfo.screenHeight); + maxResolution.width = Math.max(1920, deviceInfo['screenWidth']); + maxResolution.height = Math.max(1080, deviceInfo['screenHeight']); } catch (e) { shaka.log.alwaysWarn('WebOS: Error detecting screen size, default ' + 'screen size 1920x1080.');