just updated to kotliin 1.4. and when using `?:` f...
# server
j
just updated to kotliin 1.4. and when using
?:
for a nullable list I get this... (see screenshot). Known issue?
n
I don't have an answer for you, but normally I think you'd use
.orEmpty()
instead of
?: emptyList()
j
well, perhaps that would work in this case... but say that you have a hashmap and want to do
?: emptyMap()
yeah, I guess we could replace it with another extension function
.orEmptyMap()
but then what good is
?:
anymore...?