From bf51b4b1fb02ba3254807dfad39defdb16e2af34 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C3=81lvaro=20Velad=20Galv=C3=A1n?= Date: Wed, 5 May 2021 18:34:59 +0200 Subject: [PATCH] fix: Ignore network changes if ABR is disabled (#3387) Close: #3385 --- lib/abr/simple_abr_manager.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/abr/simple_abr_manager.js b/lib/abr/simple_abr_manager.js index 4ddb288642..a247aa3edf 100644 --- a/lib/abr/simple_abr_manager.js +++ b/lib/abr/simple_abr_manager.js @@ -52,7 +52,7 @@ shaka.abr.SimpleAbrManager = class { // of connectivity changes. if (navigator.connection) { navigator.connection.addEventListener('change', () => { - if (this.config_.useNetworkInformation) { + if (this.config_.useNetworkInformation && this.enabled_) { this.bandwidthEstimator_ = new shaka.abr.EwmaBandwidthEstimator(); const chosenVariant = this.chooseVariant(); if (chosenVariant) {