Smart cast, now you see it, now you dont

So the following works

Works

As it smart casts view to Button. previously the last line was button.text. All good. button is not used so will remove it.

Broke

But not it does not work. text gets ‘Unresolved reference: text’. Can someone please explain this?

submitted by /u/LifeAffect6762
[link] [comments]