katien
12/05/2017, 8:12 PMerrors.mapValues { (_, v) ->
when (v) {
is String -> listOf(v)
is List<*> -> v as List<String>
else -> listOf(v.toString())
}
}
rgoomar
12/05/2017, 8:14 PM.toString()
on a list of a different type should still get you a list of strings after listOf()
Shawn
12/05/2017, 8:16 PMMap<String, String|List<String>>
rgoomar
12/05/2017, 8:16 PM