Skip to content

Commit

Permalink
do not renew license when player hasn't started or is paused
Browse files Browse the repository at this point in the history
  • Loading branch information
harisha-swaminathan committed Jul 16, 2024
1 parent b1e0e2b commit 0e81954
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/eme.js
Original file line number Diff line number Diff line change
Expand Up @@ -161,6 +161,10 @@ export const makeNewRequest = (player, requestOptions) => {
return;
}

if (event.messageType === 'license-renewal' && (!player.hasStarted() || player.paused())) {
return;
}

getLicense(options, event.message, contentId)
.then((license) => {
resolve(keySession.update(license).then(() => {
Expand Down

0 comments on commit 0e81954

Please sign in to comment.