Accept third party cookies in WebView instances

May help with Cloudflare.

(cherry picked from commit 0ac5f3b93c9cd396f86c3989a1a77adcdae3ec12)
This commit is contained in:
arkon 2023-07-01 09:40:58 -04:00 committed by Jobobby04
parent f81f995127
commit 0eee1f1c3b

View File

@ -12,7 +12,7 @@ import tachiyomi.core.util.system.logcat
object WebViewUtil {
const val SPOOF_PACKAGE_NAME = "org.chromium.chrome"
const val MINIMUM_WEBVIEW_VERSION = 109
const val MINIMUM_WEBVIEW_VERSION = 111
fun supportsWebView(context: Context): Boolean {
try {
@ -47,6 +47,8 @@ fun WebView.setDefaultSettings() {
builtInZoomControls = true
displayZoomControls = false
}
CookieManager.getInstance().acceptThirdPartyCookies(this)
}
private fun WebView.getWebViewMajorVersion(): Int {