diff --git a/app/src/main/java/app/revanced/manager/di/HttpModule.kt b/app/src/main/java/app/revanced/manager/di/HttpModule.kt index 38621b0c43..1d827ce633 100644 --- a/app/src/main/java/app/revanced/manager/di/HttpModule.kt +++ b/app/src/main/java/app/revanced/manager/di/HttpModule.kt @@ -1,9 +1,11 @@ package app.revanced.manager.di import android.content.Context +import app.revanced.manager.BuildConfig import io.ktor.client.* import io.ktor.client.engine.okhttp.* import io.ktor.client.plugins.HttpTimeout +import io.ktor.client.plugins.UserAgent import io.ktor.client.plugins.contentnegotiation.* import io.ktor.serialization.kotlinx.json.* import kotlinx.serialization.json.Json @@ -40,6 +42,9 @@ val httpModule = module { install(HttpTimeout) { socketTimeoutMillis = 10000 } + install(UserAgent) { + agent = "ReVanced-Manager/${BuildConfig.VERSION_CODE}" + } } fun provideJson() = Json {