From de3007e68ea7ee3793143816f8430703ee82fadb Mon Sep 17 00:00:00 2001 From: Robert Jaros Date: Wed, 6 Nov 2019 18:38:41 +0100 Subject: Fix parameters deserialialization --- .../src/main/kotlin/pl/treksoft/kvision/remote/KVServiceManager.kt | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'kvision-modules/kvision-server-ktor/src/main/kotlin/pl') diff --git a/kvision-modules/kvision-server-ktor/src/main/kotlin/pl/treksoft/kvision/remote/KVServiceManager.kt b/kvision-modules/kvision-server-ktor/src/main/kotlin/pl/treksoft/kvision/remote/KVServiceManager.kt index 62ce4f0c..8b766aee 100644 --- a/kvision-modules/kvision-server-ktor/src/main/kotlin/pl/treksoft/kvision/remote/KVServiceManager.kt +++ b/kvision-modules/kvision-server-ktor/src/main/kotlin/pl/treksoft/kvision/remote/KVServiceManager.kt @@ -23,6 +23,7 @@ package pl.treksoft.kvision.remote import com.fasterxml.jackson.databind.module.SimpleModule import com.fasterxml.jackson.module.kotlin.jacksonObjectMapper +import com.fasterxml.jackson.module.kotlin.readValue import io.ktor.application.ApplicationCall import io.ktor.application.call import io.ktor.http.cio.websocket.CloseReason @@ -563,7 +564,7 @@ actual open class KVServiceManager actual constructor(val serviceClass: if (T::class == String::class) { str as T } else { - mapper.readValue(str, T::class.java) + mapper.readValue(str) } } ?: null as T } -- cgit