Variations of the word "Schadenfreude"
Solution 1:
I believe the most appropriate term for that situation is that one is feeling revenged.
Solution 2:
I can't think if a phrase for the feeling, but
- "just deserts" is used to describe what the other person is felt to receive; and
- "poetic justice" may describe the circumstances: the fact that they do receive their just deserts.