mirror of
https://github.com/topjohnwu/Magisk.git
synced 2024-11-24 02:25:28 +00:00
Show User-Agent
This commit is contained in:
parent
bc0c1980db
commit
5be3bd1e64
@ -63,6 +63,12 @@ fun createOkHttpClient(context: Context): OkHttpClient {
|
||||
})
|
||||
}
|
||||
|
||||
builder.addInterceptor { chain ->
|
||||
val request = chain.request().newBuilder()
|
||||
request.header("User-Agent", "Magisk ${BuildConfig.VERSION_CODE}")
|
||||
chain.proceed(request.build())
|
||||
}
|
||||
|
||||
if (!ProviderInstaller.install(context)) {
|
||||
Info.hasGMS = false
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user