In koltin it's common to check the input argument to avoid null value, and I often write a lot of codes like this:
fun test(text: String?) {
text ?: return
// do other things based of text
}
Is this a good coding style? Or there is a better one? Thanks for any comment!