migrate to RxJava3 (#2146)

* migrate to RxJava3

* remove unused import
This commit is contained in:
Konrad Pozniak 2021-05-16 19:53:27 +02:00 committed by GitHub
commit 40b24cd242
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
59 changed files with 200 additions and 197 deletions

View file

@ -34,7 +34,7 @@ import okhttp3.OkHttp
import okhttp3.OkHttpClient
import okhttp3.logging.HttpLoggingInterceptor
import retrofit2.Retrofit
import retrofit2.adapter.rxjava2.RxJava2CallAdapterFactory
import retrofit2.adapter.rxjava3.RxJava3CallAdapterFactory
import retrofit2.converter.gson.GsonConverterFactory
import retrofit2.create
import java.net.InetSocketAddress
@ -110,7 +110,7 @@ class NetworkModule {
return Retrofit.Builder().baseUrl("https://" + MastodonApi.PLACEHOLDER_DOMAIN)
.client(httpClient)
.addConverterFactory(GsonConverterFactory.create(gson))
.addCallAdapterFactory(RxJava2CallAdapterFactory.createAsync())
.addCallAdapterFactory(RxJava3CallAdapterFactory.create())
.build()
}