Need help with regex

It’s not understandable for me, but the second definition works now. No idea, why it didn’t work before, but I guess, somewhere I made a small mistake. Sorry, for my useless post 😉