I am reminded of author Don Miguel Ruiz and The Four Agreements, the second Agreement is this one:
Don't Take Anything Personally: Nothing others do is because of you. What others say and do is a projection of their own reality, their own dream. When you are immune to the opinions and actions of others, you won't be the victim of needless suffering.