mirror of
https://github.com/facebook/react-native.git
synced 2025-11-01 09:14:26 +00:00
fix: crash while loading webview (#33867)
Summary: This will fix a crash on Motorola devices on Android 7, where WebView fails to load due to initialisation issues in the WebViewChromiumFactoryProvider (Caused by org.chromium.base.library_loader.ProcessInitException). ## Changelog [Android][Fix] - Exception with `Cannot load WebView` message will initialising WebView (along with existing checks) Pull Request resolved: https://github.com/facebook/react-native/pull/33867 Test Plan: <img width="1368" alt="Screenshot 2022-05-19 at 02 21 57" src="https://user-images.githubusercontent.com/933314/169154293-c442a54f-96f5-4309-a6ce-c8f9c4beeb17.png"> Reviewed By: javache Differential Revision: D36517673 Pulled By: cortinico fbshipit-source-id: 4fa5b903529eb04d01ed8fa540cbd883224e8e62
This commit is contained in:
committed by
Facebook GitHub Bot
parent
0605880c9e
commit
9e0d8696cc
+2
-1
@@ -151,7 +151,8 @@ public class ForwardingCookieHandler extends CookieHandler {
|
||||
if (exception.getClass().getCanonicalName().contains("MissingWebViewPackageException")
|
||||
|| (message != null
|
||||
&& (message.contains("WebView provider")
|
||||
|| message.contains("No WebView installed")))) {
|
||||
|| message.contains("No WebView installed")
|
||||
|| message.contains("Cannot load WebView")))) {
|
||||
return null;
|
||||
} else {
|
||||
throw exception;
|
||||
|
||||
Reference in New Issue
Block a user