100% this. I've been overweight to varying degrees for most of my life, but my weight has been at its lowest when I'm happy and highest when I have high stress or anxiety. Anxiety especially seems to lead to poor eating because you go into survival mode and stop being able to think long term, while loading up on food as if you were a hunter gatherer about to go through times of extreme food uncertainty.