Created
December 13, 2020 11:19
-
-
Save gokmenbayram/a28b2f3ce2844916eb861629d402f43c to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
object ApiClient { | |
private var retrofit: Retrofit? = null | |
fun api(url: String): Retrofit { | |
retrofit = | |
Retrofit.Builder() | |
.baseUrl(url) | |
.addConverterFactory(GsonConverterFactory.create()) | |
.build() | |
return retrofit as Retrofit | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment