-
Notifications
You must be signed in to change notification settings - Fork 3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Completion handler passed to -[WKPrivateNavigationDelegate webView:decidePolicyForNavigationAction:decisionHandler:] was called more than once #278
Comments
(I updated your issue to make your code render in Markdown... makes it easier to read) Your conditionals allow for more than one handler to be called. Perhaps try and make the statements mutually exclusive?
|
same issue. I met this problem on iOS 11 devices. |
got the same problem and not fix yet |
add |
|
the code need to be added in your own delegate, and delete the cancel action decisionHandler(WKNavigationActionPolicyCancel); in WKWebViewJavascriptBridge.m |
Hm, why this issue is closed? I think, it is not fixed in the last version. |
I think it's duplicate with the others, the same issues has exist already. It's not fixed at all. |
Adding 'return'. Can't solve the problem on me. It seems some sutiation it doesn't enter : “ if ([_base isWebViewJavascriptBridgeURL:url]) ” i fix this bug with adding these code in Delegate method:
With these, you can compulsively enter IF and execute return . |
Fixed in latest release (6.0.3) |
|
You should declare an interface by protocol at the .h file, so the xcode can recognize this. And by the way, we always use the latest version Xcode to avoid strange problems on iOS, I recommend you to do it as well. |
What is the purpose of this method?
|
I implement the selector @selector(webView:decidePolicyForNavigationAction:decisionHandler:)
and execute "decisionHandler(WKNavigationActionPolicyAllow);"
It seems the decisionHandler can be called twice and cause the crash.
No such thing has happened before...
The text was updated successfully, but these errors were encountered: