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

Fix closeMenu() when not yet fully upgraded #49

Merged
merged 4 commits into from
Feb 14, 2024

Conversation

MattiasBuelens
Copy link
Collaborator

When rapidly creating and destroying the UI (such as when using Webpack's Hot Module Replacement), I ran into an edge case where UIContainer._onSourceChange was called before the <theoplayer-menu-group> was properly registered. This led to a TypeError when trying to call closeMenu() on a non-upgraded element.

This should hopefully fix that.

@MattiasBuelens MattiasBuelens added the bug Something isn't working label Feb 13, 2024
@MattiasBuelens MattiasBuelens merged commit b874fe3 into main Feb 14, 2024
1 check passed
@MattiasBuelens MattiasBuelens deleted the fix-closemenu-not-defined branch February 14, 2024 10:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant