There is an old saying that the first time someone does you wrong, you blame them, but the second time they do you wrong, you blame yourself for giving them the opportunity to do that to you. Although the quote is rather famous in writing, practically things are very different. You can’t judge someone’s intentions based on one event. There comes the huge role that empathy plays in your life.
What you need to do is give people the benefit of the doubt at times. Put yourself in their shoes and think about why they did what they did. They might not be able to explain themselves to you but sometimes you need to think about things from their perspective and be understanding of the issues that they might be having in their life. They might be pressured or have no option but to put their own needs ahead of yours. That does not make them a bad person, it simply means that they had circumstances that forced their hand. If you start crossing out people from your life based on one event, then there is a good chance you will develop trust issues or have a hard time forming connections with people.
Of course, this does not mean that you become a pushover and allow everyone to step on you. It is a simple understanding of how you should form impressions of people. The first time someone does you wrong, you can go confront them or choose to avoid that and ignore the situation, but either way, you don’t change how you deal with them. You simply form a hypothesis or an opinion about them while making sure you are open to changing those opinions. See if there is some good in the person and if there is only little good in them, you can always limit your interactions with them. Burning bridges and having open conflict with people can lead to awkward situations, especially if there is a chance that you may need to work together or be in the same room in times to come.