What can you do to prevent this??

Well the good news is that there’s plenty you can do. Here is something to start with

1. Control your emotions.
2. Recognize things that irritate and anger you.
3. Practice stress management and anger management techniques.
4. Exercise. Eat well.

The best solution is to develop a longer fuse and not get angry in the first place. If that is not possible, recognize your anger and the situations that make you angry. Try to resolve them in a positive way. If things are not in your control, accept them and learn to take it in your stride.