diff --git a/app/src/main/java/eu/m724/vastapp/vastai/api/InstancesUrlRequestCallback.kt b/app/src/main/java/eu/m724/vastapp/vastai/api/InstancesUrlRequestCallback.kt index 0a54fb5..da5eb1d 100644 --- a/app/src/main/java/eu/m724/vastapp/vastai/api/InstancesUrlRequestCallback.kt +++ b/app/src/main/java/eu/m724/vastapp/vastai/api/InstancesUrlRequestCallback.kt @@ -1,6 +1,7 @@ package eu.m724.vastapp.vastai.api import eu.m724.vastapp.vastai.ApiFailure +import eu.m724.vastapp.vastai.data.Instance import eu.m724.vastapp.vastai.data.User import org.chromium.net.CronetException import org.chromium.net.UrlRequest @@ -10,7 +11,7 @@ import java.nio.ByteBuffer import java.nio.charset.CodingErrorAction class InstancesUrlRequestCallback( - val onSuccess: (List) -> Unit, + val onSuccess: (List) -> Unit, val onFailure: (ApiFailure) -> Unit ) : UrlRequest.Callback() { @@ -42,14 +43,14 @@ class InstancesUrlRequestCallback( override fun onSucceeded(request: UrlRequest?, info: UrlResponseInfo?) { if (info?.httpStatusCode == 200) { val jsonResponse = JSONObject(stringResponse.toString()) - val instances = ArrayList() + val instances = ArrayList() val instancesJson = jsonResponse.getJSONArray("instances") for (i in 0..