Well maybe you problem is that you are too nice a person and talk to everyone.
Perhaps you need to learn to make better judgments on people.
You don't have to like or become involved with everyone you meet. You have to set boundaries and build barriers or you will continue to be hurt.