Hey guys, I am trying to write a simple json api with kotlin and the spark framework. All was going well until I tried to convert what I assume to be an anonymous function to an actual function, could anyone help out?
val toJson: (Any) -> String = {
gson.toJson(it)
}