That is one way of looking at it, but here's another way:
As long as barzani was on the good side of Turkey they were prospering. They were almost like another gulf oil-rich state, right in the middle of a mess. Iraq couldn't do anything, absolutely anything despite barking 24/7. Neither could Iran or anyone else. The day they crossed Turkey and bit the hand that fed them Turkey stopped protecting Barzani, Iraq retook kirkuk, all international flights to KRG are banned, oil exports of the regional government have stopped. KRG turned from Dubai to zimbabwe overnight. And last but not least, Barzani stepped down.
Yes, Turkey did say that. But Turkey is a reasonable country. It doesn't incessantly insist on things when there are more important things. Manbij was under ISIS control and US gave solid promises that once Manbij is captured YPG would retreat. And since at least until that time we were allies with the US we trusted them. Our only fault there was trusting an unreliable ally. Now that we see the real face of the US that won't be happening any time soon unless US shows some solid steps towards fulfilling their promises.
Afrin is a huge swathe of strategic land through which YPG has launched more than 700 attacks into Turkey since they captured the territory. It may not make a difference to you, but for us it makes all the difference.