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

Throw an exception when authors pass an unsupported constructor or element to getAutoplayPolicy() #17

Closed
alastor0325 opened this issue Jan 10, 2022 · 0 comments · Fixed by #18

Comments

@alastor0325
Copy link
Collaborator

This is from here, authors might pass an unsupported parameter to navigator.getAutoplayPolicy(ctor) and navigator.getAutoplayPolicy(object).

When that situation happens, those methods should throw type error, like this example. Currently we only support constructor and element for HTMLMediaElement and AudioContext, all other constructors or elements passed to the methods should cause throwing an exception.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
1 participant