Yes. A somewhat better way to say that is as follows:
It is possible for attachment to worldly things to happen (taṇhā) as long as the dangers of attaching to worldly things are not comprehended.
– That understanding grows as paññā grows.
– Thus, the tendency to attach to worldly things starts to fade away at the Sotapanna Anugami stage.