I let my ego take over today and argued with my mum. she said something that really got to me and I just had to say something back. which I hate

How do you guys deal with keeping your ego in check and not letting things affect you?