Undoubtedly this action which you used to do is one of the forbidden things which are not pleasing to Allaah. Please see question no. 1114.
But the Bounty of Allaah is immense and He is the Most Merciful of those who show mercy. He is more merciful than a mother towards her child. Hence repentance wipes out whatever came before. If a person repents sincerely to Allaah, then Allaah will forgive him. Allaah says (interpretation of the meaning):
“O you who believe! Turn to Allaah with sincere repentance! It may be that your Lord will expiate from you your sins, and admit you into Gardens under which rivers flow (Paradise)”
Ibn Katheer said, [the phrase] ‘it may be’ in the case of Allaah means that He will definitely [do that].
And it says in the hasan hadeeth which was narrated by Ibn Maajah from Abu ‘Ubaydah ibn ‘Abd-Allaah from his father that he said: “The Messenger of Allaah (peace and blessings of Allaah be upon him) said: ‘The one who repents from sin is like one who did not sin.’” (al-Zuhd, 4240; classed as hasan by al-Albaani in Saheeh Sunan Ibn Maajah, no. 3427). Undoubtedly when the Muslim turns back to Allaah and repents to Him, this is something which fills the heart with gladness. How can it be otherwise, when Allaah Himself rejoices over that? It says in the hadeeth which was narrated by Imaam Muslim in his Saheeh from Abu Hurayrah (may Allaah be pleased with him) that the Messenger of Allaah (peace and blessings of Allaah be upon him) said: “By Allaah, Allaah rejoices more over the repentance of His slave than one of you who finds his lost camel in the wilderness.” (Kitaab al-Tawbah, 4927). So praise Allaah for helping you to repent and for guiding you to the right path. Beware of returning to misguidance after having been guided. You have to remain steadfast and not take lightly any forbidden thing that you did before you repented. Keep away from bad friends, and be patient and persevere in doing so, because bad friends will do their utmost to hold you back and make you doubt that Allaah has forgiven you. Do not pay attention to anything of that kind, rather strive to draw closer to Allaah by obeying and worshipping Him. Try to find alternative friends among righteous women so that they can help you to follow the path of guidance. We ask Allaah to help you adhere firmly to His religion and His way.
And Allaah knows best. May Allaah bless our Prophet Muhammad.