mirror of
https://github.com/topjohnwu/Magisk.git
synced 2024-12-24 20:17:40 +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…
x
Reference in New Issue
Block a user