Emotions that we regard as bad may be useful.

https://theconversation.com/anger-sadness-boredom-anxiety-emotions-that-feel-bad-can-be-useful-217654