From 743d093a5dc4290001fcae79ac545156df9334f3 Mon Sep 17 00:00:00 2001 From: Robert Jaros Date: Sat, 8 Feb 2020 15:51:55 +0100 Subject: Fix error handling --- .../src/main/kotlin/pl/treksoft/kvision/remote/CallAgent.kt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'kvision-modules/kvision-remote/src/main/kotlin/pl/treksoft') diff --git a/kvision-modules/kvision-remote/src/main/kotlin/pl/treksoft/kvision/remote/CallAgent.kt b/kvision-modules/kvision-remote/src/main/kotlin/pl/treksoft/kvision/remote/CallAgent.kt index 5112a49c..9110d4df 100644 --- a/kvision-modules/kvision-remote/src/main/kotlin/pl/treksoft/kvision/remote/CallAgent.kt +++ b/kvision-modules/kvision-remote/src/main/kotlin/pl/treksoft/kvision/remote/CallAgent.kt @@ -88,7 +88,7 @@ open class CallAgent { this.error = { xhr: JQueryXHR, _: String, errorText: String -> val message = if (xhr.responseJSON != null && xhr.responseJSON != undefined) { - xhr.responseJSON.toString() + NativeJSON.stringify(xhr.responseJSON) } else if (xhr.responseText != undefined) { xhr.responseText } else { -- cgit