From 512baaa43f659881b32510814c65d49858d1f1c8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Kuba=20Szczodrzy=C5=84ski?= Date: Sun, 19 Jan 2020 20:34:10 +0100 Subject: [PATCH] [Errors] Include parser error body when reporting HTTP errors. --- .../java/pl/szczodrzynski/edziennik/data/api/models/ApiError.kt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/src/main/java/pl/szczodrzynski/edziennik/data/api/models/ApiError.kt b/app/src/main/java/pl/szczodrzynski/edziennik/data/api/models/ApiError.kt index f9c553a4..42a41b8e 100644 --- a/app/src/main/java/pl/szczodrzynski/edziennik/data/api/models/ApiError.kt +++ b/app/src/main/java/pl/szczodrzynski/edziennik/data/api/models/ApiError.kt @@ -93,7 +93,7 @@ class ApiError(val tag: String, var errorCode: Int) { stackTrace = throwable?.stackTraceString, request = requestString, response = responseString, - apiResponse = apiResponse, + apiResponse = apiResponse ?: response?.parserErrorBody, isCritical = isCritical ) }