Ignore webview init exceptions (#1124)

This commit is contained in:
Rafał Borcz 2021-02-03 20:59:24 +01:00 committed by GitHub
parent 1fdbdf34b9
commit a063aabc7c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -86,7 +86,11 @@ class WulkanowyApp : Application(), Configuration.Provider {
private fun fixWebViewLocale() {
//https://stackoverflow.com/questions/40398528/android-webview-language-changes-abruptly-on-android-7-0-and-above
WebView(this).destroy()
try {
WebView(this).destroy()
} catch (e: Exception) {
//Ignore exceptions
}
}
override fun getWorkManagerConfiguration() = Configuration.Builder()