The uestion you ask, is what can you do to stop this problem, or at least alleviate it.
The best I can suggest is a course of CBT(Cognitive Behaviour Therapy). This is defined as a practical, structured talking therapy that helps you manage mental health and behavioral challenges. It works by identifying the connection between your thoughts, feelings, and actions, and teaching you practical coping strategies to break negative cycles and improve your mood
You should be able to get a referral through your doctor, or, if you go online to your GP Practice website, Among all the nitty gritty about appointments and prescriptions, they also have pages of accessible information about mental and physical health and may have information about CBT courses there