Skip to content

Conversation

@seer-by-sentry
Copy link
Contributor

Fixes ECENCY-NEXT-VM6. The issue was that: iOS Safari's strict cross-origin policies block iframe video embeds, causing DOM elements to be null, leading to TypeError when accessed.

  • Implemented a more robust isElementSafe function to check if the post body element is safe to access, including handling potential SecurityError exceptions in iOS Safari due to cross-origin iframe restrictions.
  • Added more specific error handling and logging for iOS Safari related issues, such as null is not an object errors and SecurityError exceptions, to aid in debugging.
  • Ensured that the element's isConnected property is checked safely, with a fallback mechanism if the check fails due to security restrictions.
  • Improved error logging to provide more context when enhancements fail, including specific messages for DOM structure issues and cross-origin security errors.

This fix was generated by Seer in Sentry, triggered automatically. 👁️ Run ID: 29630

Not quite right? Click here to continue debugging with Seer.

@feruzm feruzm merged commit 80dd6b7 into develop Sep 24, 2025
@feruzm feruzm deleted the seer/safe-dom-enhancements branch September 24, 2025 09:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants