Salaam Allaikum,
Ultimately, human beings will make mistakes from time to time. The answer here is very simple: Seek sincere repentance from God with full regret for the action. God has promised us that when we seek repentance from him, he will definitely accept it from us. He is just waiting for us to feel regret and ask him for forgiveness.
Once you have done that, know with certainty that you have been forgiven and move on with your life. Consider yourself forgiven as if you had never committed that sin....
May Allah give blessings and barakah to your life...