Answers for "okhttp3-response-body-string-always-returns-empty"

0

okhttp3-response-body-string-always-returns-empty

@Override
            public void onResponse(@NotNull Call call, @NotNull Response response) throws IOException {
                if (response.isSuccessful()) {
                    String myResponse = response.peekBody(99999L).string();
                    Log.i("string", myResponse);
                }
            }
Posted by: Guest on October-05-2021

Browse Popular Code Answers by Language