Skip to content

Commit 920f0f8

Browse files
mdvaccafacebook-github-bot
authored andcommitted
Avoid debug crash when SendAccessibilityEventMountItem fails due to view dissapearing (#50021)
Summary: Pull Request resolved: #50021 Avoid debug crash when SendAccessibilityEventMountItem fails due to view dissapearing changelog: [internal] internal Reviewed By: makovkastar Differential Revision: D71135286 fbshipit-source-id: b75f048ac241d2001eade8f0dd19234bdd55178f
1 parent 5d10012 commit 920f0f8

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

packages/react-native/ReactAndroid/src/main/java/com/facebook/react/fabric/mounting/mountitems/SendAccessibilityEventMountItem.kt

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@
77

88
package com.facebook.react.fabric.mounting.mountitems
99

10+
import com.facebook.react.bridge.ReactNoCrashSoftException
1011
import com.facebook.react.bridge.ReactSoftExceptionLogger
1112
import com.facebook.react.bridge.RetryableMountingLayerException
1213
import com.facebook.react.fabric.mounting.MountingManager
@@ -30,7 +31,7 @@ internal class SendAccessibilityEventMountItem(
3031
// due to race conditions (like the view disappearing after the event is
3132
// queued and before it executes), we log a soft exception and continue along.
3233
// Other categories of errors will still cause a hard crash.
33-
ReactSoftExceptionLogger.logSoftException(TAG, e)
34+
ReactSoftExceptionLogger.logSoftException(TAG, ReactNoCrashSoftException(e))
3435
}
3536
}
3637

0 commit comments

Comments
 (0)