Trying to do this:
var = obj?.Prop ?: obj.Prop.toLowerCase()
But I keep getting:
java.lang.NullPointerException: Cannot get property 'Prop' on null object
Isn't this what ? is for? My understanding is obj?.Prop is the same as:
if ( obj != null && obj.Prop ) { .. }
Sometimes obj is null, but if its not I want to set obj.Prop to lower case- cant set toLowerCase() on a null object