Skip to content

Instantly share code, notes, and snippets.

@ziginsider
Created August 31, 2020 11:50
Show Gist options
  • Save ziginsider/6a0137037c701101366c0ef52c8da672 to your computer and use it in GitHub Desktop.
Save ziginsider/6a0137037c701101366c0ef52c8da672 to your computer and use it in GitHub Desktop.
val okHttpClient = OkHttpClient()
okHttpClient.newCall(requestOne).enqueue(object : Callback {
override fun onFailure(call: Call, e: IOException) {
Log.e(TAG, e)
}
override fun onResponse(call: Call, response: Response) {
client.newCall(requestTwo).execute()
}
})
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment