Skip to content

Commit

Permalink
Don't show (1 of 1) display next to the ad countdown (googleads#232)
Browse files Browse the repository at this point in the history
  • Loading branch information
jgubman authored and shawnbuso committed Jul 1, 2016
1 parent e4a7329 commit 5146ceb
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/videojs.ima.js
Original file line number Diff line number Diff line change
Expand Up @@ -427,7 +427,8 @@
var currentTime = duration - remainingTime;
currentTime = currentTime > 0 ? currentTime : 0;
var isPod = false;
var adPosition, totalAds;
var totalAds = 0;
var adPosition;
if (currentAd.getAdPodInfo()) {
isPod = true;
adPosition = currentAd.getAdPodInfo().getAdPosition();
Expand All @@ -441,7 +442,7 @@
remainingSeconds = '0' + remainingSeconds;
}
var podCount = ': ';
if (isPod) {
if (isPod && (totalAds > 1)) {
podCount = ' (' + adPosition + ' of ' + totalAds + '): ';
}
countdownDiv.innerHTML =
Expand Down

0 comments on commit 5146ceb

Please sign in to comment.