Craving Restriction

I have been on a diet most of my life and finally have been on a good track with nutrition and exercise.

I have recently injured myself, so movement is tough and now I find myself craving restriction and falling into old habits. Will this ever go away?