Use query instead findOneBy

I don't know why but FindOneBy don't work in my case.