So I need help. 😣

So yesterday I was at the store getting gas, and I seen the man I used to date on and off again for 5 years. I immediately turned around because I was with my current boyfriend. But all of a sudden, my emotions started to get tangled up and I started thinking about the other man. How I missed what we had, all the fun we had together. I'm so confused as to what to do. I love my boyfriend, but I'm not sure why I have these emotions going through my head. Am I a bad person?