assign webView's delegate to nil

Summary:
assign webView’s delegate to nil when the delegate release
Closes https://github.com/facebook/react-native/pull/5574

Reviewed By: svcscm

Differential Revision: D2869485

Pulled By: nicklockwood

fb-gh-sync-id: c72ac64e6c8757a2095d4e5d7baa3a0b6bded6ce
This commit is contained in:
tuyou 2016-01-27 02:49:12 -08:00 committed by facebook-github-bot-9
parent e33e6ab1f0
commit 3f97c5a340

View File

@ -35,6 +35,11 @@ NSString *const RCTJSNavigationScheme = @"react-js-navigation";
NSString *_injectedJavaScript;
}
- (void)dealloc
{
_webView.delegate = nil;
}
- (instancetype)initWithFrame:(CGRect)frame
{
if ((self = [super initWithFrame:frame])) {