How do you stop feeling awful about a small mistake

Whenever someone tells me ive done something wrong (especially if its someone with authority) I can feel awful about it for days.