What makes it bother you?
Everyone has priorities in life at each point in life, which affects how they behave with others. Considering ourselves, we are not completely the same person, at a different phase of our lives. People are learned, decisions are made, we stay and we leave.
Why does it bother you when another person's priorities suddenly change?
Somewhere in life, we start expecting so much from someone and not being able to gain the same priority they once did. We end up concentrating on our guilt to gain the same priority they once had. It hurts us when we don't get the same place and priority in our lives.
When your energy goes into making others happy, you neglect your own feelings. You spend all your time and energy worrying about how others feel and neglect your own. You lose everything with it since you can't change someone who doesn't care about you.
We should start accepting that what others do is in their interest and what we do is for ours. You can't be good for everyone all the time. We should only be concerned about ourselves.
Self-love is not selfish. Why should you put other people's priorities on top of your own? Why should you depend on someone else's priority on you if you can do it better on your own?
We must not prioritise everyone in life, but it does not mean that we should not prioritize anyone. Your top priority should be a person who is doing their best to stay after you.
So, stop focusing on people who don't prioritize you and start treating the person who wants to stay as a priority.