Browse Source

Fix crash with scrollViewDidEndDecelerating and RCTTextView (#1630)

See https://github.com/wix/react-native-navigation/issues/1446#issuecomment-319858633
Blair Vanderhoof 7 years ago
parent
commit
33e861478c
1 changed files with 1 additions and 1 deletions
  1. 1
    1
      ios/RCCViewController.m

+ 1
- 1
ios/RCCViewController.m View File

@@ -277,7 +277,7 @@ const NSInteger TRANSPARENT_NAVBAR_TAG = 78264803;
277 277
 // Back to normal after user start scroll with momentum
278 278
 - (void)_traverseAndCall:(UIView*)view
279 279
 {
280
-  if([view isKindOfClass:[UIScrollView class]]) {
280
+  if([view isKindOfClass:[UIScrollView class]] && ([[(UIScrollView*)view delegate] respondsToSelector:@selector(scrollViewDidEndDecelerating:)]) ) {
281 281
     [[(UIScrollView*)view delegate] scrollViewDidEndDecelerating:(id)view];
282 282
   }
283 283