From your question it sounds as though you are struggling to determine the Lord’s will. This can be hard at times for all of us, when emotions are involved and we second guess ourselves.
If in the past you asked for the Lord’s direction and they moved to a different town, then the Lord answered your prayers. Presently, those people are geographically out of your life. But getting a person out of our thoughts is not as easy as moving away! Should we make decisions based on thoughts/emotions or principles? Truly, our thoughts and emotions are not always good indicators of the Lord’s will. We have all had the experience of thinking poorly of someone when we are really mad. But when that same person apologies and blesses us, we shift and think he is wonderful. That person didn’t change; our feelings did. Decisions should be based on God’s principles, not on our emotions. Remember, our hearts can trick us, “The heart is deceitful above all things and desperately wicked: who can know it?” (Jeremiah 17:9) Toiling over decisions in the past can rob us of the joy and peace in the present. We don’t want to be double-minded. (James 1:8)
Go over in your mind again the reasons why you thought they were not good for you. Did they take you away from the Lord and living a Christian life? Did they involve you in worldly activities? Jesus’ answer is, “Seek first the kingdom of God and His righteousness” (Matthew 6:33)
When you say you can’t stop thinking about and praying for them that’s a wonderful attitude to have. We don’t want a root of bitterness to grow in our hearts. (Hebrews 12:15) What do your actions reveal about you? They reveal you are a caring person but at the same time want to do what’s right. It’s a hard balance to maintain.
If you truly want the Lord’s will done in your life, then stay close to Him. ”Trust in the Lord with all your heart, lean not unto your own understanding. In all your ways acknowledge Him and He shall direct your paths.” Proverbs 3:5,6