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: prevent possible error on embedded component disconnect #20260

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

web-padawan
Copy link
Member

Description

This fixes the following error which sometimes occurs when switching between docs pages with Java examples:

Uncaught TypeError: Cannot read properties of undefined (reading 'disconnected')
    at ContextMenuPresentationWc.disconnectedCallback (:8000/vaadin/VAADIN/generated/flow/web-components/context-menu-presentation-wc.js:131:18)
    at removeChild (chunk-UXDD7MME.js:8456:26)

I'm not sure how to test this but it makes sense to check for object being defined before calling its methods anyway.

Type of change

  • Bugfix

Copy link

sonarcloud bot commented Oct 16, 2024

Copy link

Test Results

1 142 files  ± 0  1 142 suites  ±0   1h 25m 21s ⏱️ + 1m 29s
7 464 tests ± 0  7 414 ✅ ± 0  50 💤 ±0  0 ❌ ±0 
7 797 runs  +17  7 737 ✅ +17  60 💤 ±0  0 ❌ ±0 

Results for commit 7405061. ± Comparison against base commit 1937249.

@mshabarov mshabarov added the Contribution PRs coming from the community or external to the team label Oct 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Contribution PRs coming from the community or external to the team +0.0.1
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants