Work on developing other social relationships outside of work. If the other people at work treat you badly because of something someone else said, they are likely not good friends anyway. People who make judgments about others without the full story are not worth your time. Find other things to do where you can make friends who appreciate you for you.