voddan
07/03/2017, 1:11 PMcoAuthor is a val property, than the best way to deal with a null is to put coAuthor ?: return in the begging of your method. As was mentioned, it won't work in if it is a var property because of multithreading issues. In that case I think the convention is to overshadow the name and ignore the warning val coAuthor = coAuthor ?: return