diff --git a/src/ext/lib/ar-detect/ArDetector.js b/src/ext/lib/ar-detect/ArDetector.js index c73132b..69cb851 100644 --- a/src/ext/lib/ar-detect/ArDetector.js +++ b/src/ext/lib/ar-detect/ArDetector.js @@ -564,11 +564,8 @@ class ArDetector { this.drmNotificationShown = true; // if we detect Edge, we'll throw the aggressive popup - if (BrowserDetect.isEdgeUA() && !this.settings.active.mutedNotifications?.browserSpecific?.edge?.brokenDrm?.[window.hostname]) { - new PlayerUi(this.element, this.settings); - } else { - this.conf.player.showNotification('AARD_DRM'); - } + this.conf.player.showEdgeNotification(); + this.conf.player.showNotification('AARD_DRM'); this.conf.resizer.setAr({type: AspectRatio.Reset}); return; diff --git a/src/ext/lib/video-data/PlayerData.js b/src/ext/lib/video-data/PlayerData.js index 79a9253..21caaa9 100644 --- a/src/ext/lib/video-data/PlayerData.js +++ b/src/ext/lib/video-data/PlayerData.js @@ -480,6 +480,15 @@ class PlayerData { showNotification(notificationId) { this.notificationService?.showNotification(notificationId); } + + /** + * NOTE: this method needs to be deleted once Edge gets its shit together. + */ + showEdgeNotification() { + if (BrowserDetect.isEdgeUA() && !this.settings.active.mutedNotifications?.browserSpecific?.edge?.brokenDrm?.[window.hostname]) { + this.ui = new PlayerUi(this.element, this.settings); + } + } } if (process.env.CHANNEL !== 'stable'){