Commit 176ece5
Fix RCTDevLoadingView crash when adding button constraints (#54690)
Summary:
Changelog:
[iOS][Fixed] - Fixed crash from dismiss button in DevLoadingView
D86420230 added a dismiss button feature to RCTDevLoadingView. However, when adding layout constraints on line 198, it incorrectly checked the `dismissButton` parameter instead of the `self->_dismissButton` instance variable. This caused NSLayoutConstraint crashes when the parameter was nil/false but the instance variable existed from a previous call, or vice versa.
This changes line 198 to check `self->_dismissButton` (the instance variable) instead of `dismissButton` (the function parameter) to properly verify if the button exists before adding constraints to it.
Reviewed By: vzaidman, javache
Differential Revision: D878718561 parent 7163033 commit 176ece5
1 file changed
+1
-1
lines changedLines changed: 1 addition & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
195 | 195 | | |
196 | 196 | | |
197 | 197 | | |
198 | | - | |
| 198 | + | |
199 | 199 | | |
200 | 200 | | |
201 | 201 | | |
| |||
0 commit comments