diff --git a/android/tangram/src/com/mapzen/tangram/MapController.java b/android/tangram/src/com/mapzen/tangram/MapController.java index 9f7af21806..ac4226a03b 100644 --- a/android/tangram/src/com/mapzen/tangram/MapController.java +++ b/android/tangram/src/com/mapzen/tangram/MapController.java @@ -10,7 +10,6 @@ import com.mapzen.tangram.TouchInput.Gestures; import okhttp3.Call; import okhttp3.Callback; -import okhttp3.Request; import okhttp3.Response; import java.io.IOException; @@ -21,8 +20,6 @@ import javax.microedition.khronos.egl.EGLConfig; import javax.microedition.khronos.opengles.GL10; -import okio.BufferedSource; - /** * {@code MapController} is the main class for interacting with a Tangram map. */ @@ -1007,8 +1004,7 @@ public void onResponse(Call call, Response response) throws IOException { nativeOnUrlFailure(callbackPtr); throw new IOException("Unexpected response code: " + response); } - BufferedSource source = response.body().source(); - byte[] bytes = source.readByteArray(); + byte[] bytes = response.body().bytes(); nativeOnUrlSuccess(bytes, callbackPtr); } });