Closed mimse closed 5 years ago
vjs-ad-loading
is removed automatically when leaving the Preroll state:
There must be more going on in your empty vast response case. Is it not changing state? If so, the complete solution would be to make sure the state is changed so the full cleanup logic can execute.
Do you have an example I could look at to help identify the issue?
Hi, @incompl
I enabled debug mode and this is the state changes that are happening.
Will try to make an example for you to test with.
Hi again @incompl
As you can see on this screenshot the vjs-ad-loading class is never removed.
To reproduce the issue download the src code from this link
https://drive.google.com/file/d/11EWqbimNlzLCEpJj4LtBZQhzXHJgLKTs/view?usp=sharing
Clicking play and reload the page until you get an empty VAST response.
Ah, it does appear that the plugin is not aware that it transitioned beyond prerolls and that is why the preroll cleanup never happened. In searching your example for the root cause, I found that the cause is autoplay. The autoplay value "true" does not work with this plugin (basically because vjs middleware can't handle play events from the video element). There are two alternatives to address this: 1) call play manually instead of using the autoplay attribute or 2) use the new string values for the autoplay option.
I´ll try that tomorrow. Thank you for looking into this.
After changing how the autoplay option was set. I could not reproduce the issue.
Thank you for helping with this, I´ll close the PR.
Glad I could help!
On Fri, Nov 16, 2018 at 3:36 AM Morten Vestergaard Hansen < notifications@github.com> wrote:
Closed #449 https://github.com/videojs/videojs-contrib-ads/pull/449.
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/videojs/videojs-contrib-ads/pull/449#event-1970659789, or mute the thread https://github.com/notifications/unsubscribe-auth/AAM4Z5TGPmClfN7voRmuOSyRgXoGHOf3ks5uvnjxgaJpZM4Yd2H2 .
If the vast request was empty the vjs-ad-loading class is not removed causing the video to be hidden behind an overlay