by seanalltogether · 9y ago · 0 comments
if let person = selection?.organization?.owner {
setTitle(person.name)
setImage(person.image)
} val person = selection?.organization?.owner?.let {
setTitle(it.name)
setImage(it.image)
it
} val person = selection?.organization?.owner?.also {
setTitle(it.name)
setImage(it.image)
} if let person1 = dashboard?.owner, person2 = selection?.organization?.owner {
person1.cloneProperties(person2)
}Would be nice if there was a multiLet in the stdlib. Probably something that happens eventually anyways.