Add the ability to hide quality options

Related to https://github.com/iv-org/invidious/pull/3011
This commit is contained in:
Émilien Devos 2022-04-13 21:01:08 +00:00 committed by GitHub
parent aa06e72932
commit ab84380b7d
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -77,6 +77,10 @@ module.exports = function(videojs) {
var player = this.player(),
sources = player.currentSources();
sources = sources.filter(function(element) {
return element.hidequalityoption == undefined;
});
return _.map(sources, function(source) {
return new QualityOption(player, {
source: source,