优化
This commit is contained in:
@@ -39,7 +39,7 @@ val cronetEngine: ExperimentalCronetEngine? by lazy {
|
||||
val engine = builder.build()
|
||||
DebugLog.d("Cronet Version:", engine.versionString)
|
||||
return@lazy engine
|
||||
} catch (e: UnsatisfiedLinkError) {
|
||||
} catch (e: Throwable) {
|
||||
AppLog.put("初始化cronetEngine出错", e)
|
||||
return@lazy null
|
||||
}
|
||||
|
||||
@@ -71,8 +71,7 @@ val okHttpClient: OkHttpClient by lazy {
|
||||
if (!AppConst.isPlayChannel && AppConfig.isCronet) {
|
||||
if (Cronet.loader?.install() == true) {
|
||||
Cronet.interceptor?.let {
|
||||
//崩溃
|
||||
//builder.addInterceptor(it)
|
||||
builder.addInterceptor(it)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user