Skip to content

Fix crash when long-pressing text after removing a link #2271 - #2766

Open
AzazelSensei wants to merge 1 commit into
singerdmx:masterfrom
AzazelSensei:fix-2271-link-long-press
Open

Fix crash when long-pressing text after removing a link #2271#2766
AzazelSensei wants to merge 1 commit into
singerdmx:masterfrom
AzazelSensei:fix-2271-link-long-press

Conversation

@AzazelSensei

Copy link
Copy Markdown

Description

Long-pressing a link, choosing remove, then long-pressing the same text crashed on a null check of the link attribute. The gesture recognizer stayed cached after the link was gone.

I dispose that recognizer when the link is removed and skip the bang if the attribute is already missing.

Related Issues

Type of Change

  • Feature: New functionality without breaking existing features.
  • 🛠️ Bug fix: Resolves an issue without altering current behavior.
  • 🧹 Refactor: Code reorganization, no behavior change.
  • Breaking: Alters existing functionality and requires updates.
  • 🧪 Tests: New or modified tests
  • 📝 Documentation: Updates or additions to documentation.
  • 🗑️ Chore: Routine tasks, or maintenance.
  • Build configuration change: Build/configuration changes.

Dispose the leftover link recognizer so a second long-press does not hit a null link attribute.

Fixes singerdmx#2271
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.

Null check operator is used on a null value when long press a link

1 participant