From f72ff2b8bd3c32ca139da35a762f9813da3ce720 Mon Sep 17 00:00:00 2001 From: Jon Date: Fri, 13 May 2016 15:24:41 -0700 Subject: [PATCH] don't show the (1 of 1) display next to the ad countdown --- src/videojs.ima.js | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/videojs.ima.js b/src/videojs.ima.js index c53c1470..9d003a2c 100644 --- a/src/videojs.ima.js +++ b/src/videojs.ima.js @@ -425,7 +425,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(); @@ -439,7 +440,7 @@ remainingSeconds = '0' + remainingSeconds; } var podCount = ': '; - if (isPod) { + if (isPod && (totalAds > 1)) { podCount = ' (' + adPosition + ' of ' + totalAds + '): '; } countdownDiv.innerHTML =