Skip to content

Commit

Permalink
Do not pause if is playing ads on mobile
Browse files Browse the repository at this point in the history
look like the mobile does not know if is playing ads
  • Loading branch information
DanielnetoDotCom committed Mar 28, 2021
1 parent 51d8b22 commit d6f202c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions view/js/script.js
Original file line number Diff line number Diff line change
Expand Up @@ -1064,8 +1064,8 @@ function playerHasAds() {
return ($("#mainVideo_ima-ad-container").length > 0);
}

function pauseIfIsPlayinAds() {
if (!player.paused() && playerHasAds() && playerIsPlayingAds()) {
function pauseIfIsPlayinAds() { // look like the mobile does not know if is playing ads
if (!isMobile() && !player.paused() && playerHasAds() && playerIsPlayingAds()) {
player.pause();
}
}
Expand Down

0 comments on commit d6f202c

Please sign in to comment.