Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bug: isVideo returns false on looping videos #324

Open
BrendaH opened this issue Oct 15, 2020 · 0 comments
Open

Bug: isVideo returns false on looping videos #324

BrendaH opened this issue Oct 15, 2020 · 0 comments
Labels
Milestone

Comments

@BrendaH
Copy link

BrendaH commented Oct 15, 2020

In a plugin I am building I want to get all video items from a presentation. To strip out anything not-video I do a check with isVideo. However, this returns false for a single looping video. After some digging I suspect that the problem is the asterisk notation behind the extension of a looping video (found in the FilePlaylist property).
This problem consists of 2 parts:

Part 1: getValue returns the file path including the asterisk notation for looping (*0*2 for example). (When I printed the value that getValue returned I also got *0*[times already looped] back).
It seems that setValue was fixed for #295/#296 but getValue was not?

Part 2: isVideo looks at the prop:srcitem (the same thing that getValue returns) and when this includes the asterisk info the regex to check if it is a video fails. Because the regex does not allow anything after the extension.

The fix would therefore probably be to have getValue not return the asterisk-part, and let isVideo() use getValue(). A workaround for me now is to add [\*,\d]* before the dollar sign of the regex.

@SML-MeSo SML-MeSo added this to the 2.11.0 milestone Jan 20, 2021
@SML-MeSo SML-MeSo added the bug label Jan 20, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants