anyone seen this error before? ```Caused by: java...
# ktor
h
anyone seen this error before?
Copy code
Caused by: java.lang.IllegalArgumentException: Response pipeline couldn't transform 'class java.util.Collections$SingletonMap' to the OutgoingContent
	at io.ktor.server.engine.BaseApplicationResponse$Companion$setupSendPipeline$1.invokeSuspend(BaseApplicationResponse.kt:271)
	at io.ktor.server.engine.BaseApplicationResponse$Companion$setupSendPipeline$1.invoke(BaseApplicationResponse.kt)
	at io.ktor.util.pipeline.SuspendFunctionGun.loop(PipelineContext.kt:268)
	at io.ktor.util.pipeline.SuspendFunctionGun.access$loop(PipelineContext.kt:67)
	at io.ktor.util.pipeline.SuspendFunctionGun.proceed(PipelineContext.kt:141)
	at io.ktor.util.pipeline.SuspendFunctionGun.execute(PipelineContext.kt:161)
	at io.ktor.util.pipeline.Pipeline.execute(Pipeline.kt:27)
n
Are you doing JSON serialisation?
s
yeah you may need to add a content negotiation strategy to your ktor application, like gson or something
Copy code
install(ContentNegotiation) {
        gson {
            setDateFormat(DateFormat.LONG)
            setPrettyPrinting()
        }
    }