Skip to content

Commit

Permalink
Don't add custom User Agent for MAL
Browse files Browse the repository at this point in the history
Closes #298
  • Loading branch information
AntsyLich committed Feb 26, 2024
1 parent 139663a commit 085ad8d
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,8 @@ class MyAnimeListInterceptor(private val myanimelist: MyAnimeList) : Interceptor
// Add the authorization header to the original request
val authRequest = originalRequest.newBuilder()
.addHeader("Authorization", "Bearer ${oauth!!.access_token}")
.header("User-Agent", "Mihon v${BuildConfig.VERSION_NAME} (${BuildConfig.APPLICATION_ID})")
// TODO: Add back custom user agent when they stop blocking us for no apparent reason
// .header("User-Agent", "Mihon v${BuildConfig.VERSION_NAME} (${BuildConfig.APPLICATION_ID})")
.build()

return chain.proceed(authRequest)
Expand Down

0 comments on commit 085ad8d

Please sign in to comment.