Eating in the middle of the night

C: I wake up to go to the toilet several times overnight
T: I must eat to get back to sleep
F: anxious
A: go and get sugary foods, wild them down hack in bed. Repeat. Numb out. Fall asleep
R: I find I can fall asleep

Any offers of this possible Ts to help with this behaviour? I feel out of control when I wake up and anxious and I soothe myself in my half awake state with carbs. Sometimes I don’t even remember doing it. I feel an immense urge and it feels like genuine hunger and it’s been a pattern for decades, but I’d prefer to change the habit.