Skip to content

Commit

Permalink
chore: Cleanup after HLS key rotation PR (#4664)
Browse files Browse the repository at this point in the history
See PR #4568, which was merged without feedback addressed.
  • Loading branch information
joeyparrish authored Nov 8, 2022
1 parent 3846eea commit 5bde080
Showing 1 changed file with 7 additions and 4 deletions.
11 changes: 7 additions & 4 deletions lib/hls/hls_parser.js
Original file line number Diff line number Diff line change
Expand Up @@ -381,9 +381,7 @@ shaka.hls.HlsParser = class {
if (!keysAreEqual(stream.keyIds, keyIds)) {
stream.keyIds = keyIds;
stream.drmInfos = drmInfos;
if (this.manifest_) {
this.playerInterface_.filter(this.manifest_);
}
this.playerInterface_.newDrmInfo(stream);
}

const segments = this.createSegments_(
Expand Down Expand Up @@ -1985,6 +1983,12 @@ shaka.hls.HlsParser = class {
/**
* @param {!shaka.hls.Playlist} playlist
* @param {string} mimeType
* @return {{
* drmInfos: !Array.<shaka.extern.DrmInfo>,
* keyIds: !Set.<string>,
* encrypted: boolean,
* aesEncrypted: boolean
* }}
* @private
*/
parseDrmInfo_(playlist, mimeType) {
Expand All @@ -2005,7 +2009,6 @@ shaka.hls.HlsParser = class {
const drmInfos = [];
const keyIds = new Set();

// TODO: May still need changes to support key rotation.
for (const drmTag of drmTags) {
const method = drmTag.getRequiredAttrValue('METHOD');
if (method != 'NONE') {
Expand Down

0 comments on commit 5bde080

Please sign in to comment.