diff --git a/AUTHORS b/AUTHORS index 988ad8164d..b0c7f19bdf 100644 --- a/AUTHORS +++ b/AUTHORS @@ -18,6 +18,7 @@ Adrián Gómez Llorente Alex Jones Alugha GmbH <*@alugha.com> Alvaro Velad Galvan +Anthony Stansbridge Bonnier Broadcasting <*@bonnierbroadcasting.com> Bryan Huh Esteban Dosztal diff --git a/CONTRIBUTORS b/CONTRIBUTORS index 667d55d54d..98777f0720 100644 --- a/CONTRIBUTORS +++ b/CONTRIBUTORS @@ -26,6 +26,7 @@ Aaron Vaage Alex Jones Alvaro Velad Galvan Andy Hochhaus +Anthony Stansbridge Ashutosh Kumar Mukhiya Benjamin Wallberg Boris Cupac diff --git a/lib/media/drm_engine.js b/lib/media/drm_engine.js index 7682938cf6..fac5a0b96a 100644 --- a/lib/media/drm_engine.js +++ b/lib/media/drm_engine.js @@ -582,7 +582,7 @@ shaka.media.DrmEngine = class { return true; } - return this.supportedTypes_.has(contentType); + return this.supportedTypes_.has(contentType.toLowerCase()); } /** @@ -831,11 +831,11 @@ shaka.media.DrmEngine = class { const videoCaps = realConfig.videoCapabilities || []; for (const cap of audioCaps) { - this.supportedTypes_.add(cap.contentType); + this.supportedTypes_.add(cap.contentType.toLowerCase()); } for (const cap of videoCaps) { - this.supportedTypes_.add(cap.contentType); + this.supportedTypes_.add(cap.contentType.toLowerCase()); } goog.asserts.assert(this.supportedTypes_.size, diff --git a/test/media/drm_engine_unit.js b/test/media/drm_engine_unit.js index 7d5807f878..0098f2d355 100644 --- a/test/media/drm_engine_unit.js +++ b/test/media/drm_engine_unit.js @@ -260,6 +260,7 @@ describe('DrmEngine', () => { expect(drmEngine.initialized()).toBe(true); expect(drmEngine.willSupport('audio/webm')).toBeTruthy(); expect(drmEngine.willSupport('video/mp4; codecs="fake"')).toBeTruthy(); + expect(drmEngine.willSupport('video/mp4; codecs="FAKE"')).toBeTruthy(); // Because DrmEngine will err on being too accepting, make sure it will // reject something. However, we can only check that it is actually