Conversation
There was a problem hiding this comment.
Pull Request Overview
This PR fixes the error handling behavior in the MessengerWebViewActivity to prevent redirecting to the app's error page when errors originate from external domains. The change ensures that only errors from the main Messenger domain trigger the error page, allowing external resources to fail gracefully without disrupting the user experience.
Key Changes
- Added domain validation before redirecting to error page
- Imported URL parsing utilities for domain comparison
- Added exception handling for malformed URLs
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
messenger/src/main/java/com/deskpro/messenger/ui/MessengerWebViewActivity.kt
Show resolved
Hide resolved
messenger/src/main/java/com/deskpro/messenger/ui/MessengerWebViewActivity.kt
Show resolved
Hide resolved
15045e8 to
4210703
Compare
qsdnikola
added a commit
that referenced
this pull request
Oct 3, 2025
* Update codeql.yml * Update README.md * DP-60 Adjust url and script * Update README.md with Java support code example * DP-36 Add inject script and validation changes (#23) * Update README.md * feat: DP-63 Build webview url (#24) * Update README.md * Update README.md * Update README.md * Update README.md * Gradle and CI update (#29) * fix: SC-199871 Prevent redirect to app error page for external domain errors (#27) Do not redirect to the App error page for errors coming from external domains. * Update README.md --------- Co-authored-by: Igor QSD <igor.maric@qsd.ba> Co-authored-by: Chris Morris <ccwm_uk@yahoo.co.uk>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.