How to Repent from Making Fun of Islam
Question

This is a very old story. it happened few months ago.once i was talking with my friends .. we were talking about something punishment in hell.then while talking i joked that when we will be punished hell .we will also beat and my friends laughed including me and i don't remember exactly but i think once i also made fun of jinns at the same time..so i asked to well known saudi scholar that we joked about punishment in hell .so he told that this invalidate your and your friends islam.i was shocked that how could this be.but now many months have passed and my friends have forgotten this.but after that they all performed umrah and also went to madinah.but they r not aware that we did this sin.so do they have to say shahada again?because one saudi scholar told me they don't have to shahada because u people keep saying shahada all the time. but i am afraid what if my friends wouldn't said shahda since that time.so if i will remind them on phone about this incident.they will think i am mad and they will be angry.trust me this is not in my capacity to tell.i hope allah would have forgiven them.or should i still remind them that ur umrah,salah etc nothing was accepted and now u have to say shahada again? because i came to know about nullifying islam recently and this thing happened many months before
Praise be to Allah.Mocking Islam: A Grave Act of Disbelief
Undoubtedly mocking and making fun of something that is known to be part of Islam constitutes disbelief that puts one beyond the pale of Islam, even if the one who does that does not mean anything more than joking , because  this in and of itself is an action that puts one beyond the pale of Islam as Allah, may He be Exalted, Says (interpretation of the meaning):
{If you ask them (about this), they declare: `We were only talking idly and joking.’ Say: `Was it at Allah, and His Ayat (proofs, evidences, verses, lessons, signs, revelations, etc.) and His Messenger (blessings and peace of Allah be upon him) that you were mocking?
Make no excuse; you have disbelieved after you had believed. If We pardon some of you, We will punish others amongst you because they were Mujrimun (disbelievers, polytheists, sinners, criminals, etc.)} [At-Tawbah 9:65-66]
The obligation to denounce mockery of Islam
What the one who is present in such a gathering must do is denounce that. If he cannot do that, then he must leave the gathering, so that he will not be a partner in the sin. If he expresses any kind of approval of their actions and words, then he is like them. Allah, may He be Exalted, Says (interpretation of the meaning):
{And when you (Muhammad (blessings and peace of Allah be upon him)) see those who engage in a false conversation about Our Verses (of the Quran) by mocking at them, stay away from them till they turn to another topic. And if the devil causes you to forget, then after the remembrance sit not you in the company of those people who are the Dhalimun (polytheists and wrongdoers, etc.)} [Al-An`am 6:68]
{And it has already been revealed to you in the Book (this Quran) that when you hear the Verses of Allah being denied and mocked at, then sit not with them, until they engage in a talk other than that; (but if you stayed with them) certainly in that case you would be like them. Surely, Allah will collect the hypocrites and disbelievers all together in Hell.} [An-Nisa’ 4:140] 
Allah, may He be Glorified and Exalted, regards the one who sits in a gathering and witnesses evil, if he does not denounce it, as being like the one who does or speaks that evil. 
Hence it is said that the one who listens is the partner of the one who backbites. According to a report, the one who witnesses sin but hates it is like the one who was absent from it, and the one who was absent from it but approves of it is like the one who witnessed it. 
Shaykh Al-Islam ibn Taymiyah (may Allah have mercy on him) said:
When some of them made fun of (the believers) and said concerning those with whom Allah is pleased, “We have never seen anyone like our people who are well-versed in the Quran when it comes to eating more or telling more lies or being more cowardly when meeting the enemy,” Allah revealed the words (interpretation of the meaning):
{The hypocrites fear lest a Surah (chapter of the Quran) should be revealed about them, showing them what is in their hearts. Say: "(Go ahead and) mock! But certainly Allah will bring to light all that you fear.’
If you ask them (about this), they declare: ‘We were only talking idly and joking.’ Say: `Was it at Allah, and His Ayat (proofs, evidences, verses, lessons, signs, revelations, etc.) and His Messenger (blessings and peace of Allah be upon him) that you were mocking?
Make no excuse; you have disbelieved after you had believed. If We pardon some of you, We will punish others amongst you because they were Mujrimun (disbelievers, polytheists, sinners, criminals, etc.)} [Al-Tawbah 9:66]
Allah informed them that they had disbelieved after having believed, even though they said, “We say words of disbelief without believing in them; rather we were just talking idly and joking.” He explained that mocking the revelations of Allah constitutes disbelief, and such words cannot be uttered except by someone who is content with such words, for if he had faith in his heart, it would have prevented him from saying such words. (End quote from Al-Iman, 2/284) 
The dangers of making fun of Islamic Teachings 
Undoubtedly making fun of any aspect of Islam is contrary to respect and veneration for this religion, especially with regard to matters such as the punishment on the Day of Resurrection, or in the grave, or the terrors of the resurrection. Islam has only told us of these things so as to alarm people and set their hearts straight, so that they will not persist in heedlessness. One of the greatest forms of heedlessness, which is indicative of being overwhelmed by ignorance, whims and desires, and lack of insight, is when one regards matters of exhortation and admonition as a joke and something to be laughed at and made fun of. 
Shaykh Al-Islam Ibn Taymiyah (may Allah have mercy on him) said concerning these hypocrites who make fun of Islam: 
This indicates that they did not themselves think that they had committed an act of disbelief; rather they thought that that did not constitute disbelief. So Allah explained that ridiculing Allah and His revelations and His Messenger constituted disbelief and meant that the person had disbelieved after having believed. This indicates that they had faith, albeit weak, and they did this prohibited action knowing that it was prohibited, but they did not think that it constituted disbelief. However it was kufr by means of which they became disbelievers, although they did not think that it was permissible. (End quote from Majmu` Al-Fatawa, 7/273) 
The one who falls into such error must renew his faith by uttering the Shahadatayn (two declarations of faith) and repent sincerely from what he has done. As for the Shahadatayn, uttering it in the prayer or in the rituals of `Umrah is sufficient. 
It says in Kashshaf Al-Qina` (6/181): 
If the disbeliever prays or gives the Adhan (call to prayer), he is deemed to be a Muslim, regardless of whether he was originally a disbeliever or had apostatised. End quote. 
How to Repent from Making Fun of Islam 
With regard to repentance, it is essential to repent sincerely and specifically from that great evil of making fun of Islam. 
Shaykh Ibn `Uthaymin (may Allah have mercy on him) said: Whoever speaks a word of disbelief, even in jest, has disbelieved. He must repent and must believe that he is repenting from apostasy. So he must renew his Islam, for the revelations of Allah, may He be Glorified and Exalted, and His Messenger, are too great to be mocked or ridiculed. (End quote from Liqa’at Al-Bab Al-Maftuh, 60/12) 
What you have mentioned about your friends is no excuse for you not to alert them to the serious sin that they have committed; rather what you must do is tell them about the ruling on what they have done, so that they may repent to Allah, may He be Exalted, from it, and they may regret it and be careful not to go back to it again. 
You can read this message to them, as an answer to your question, and similar answers having to do with the Islamic ruling on that.
For more details, please see the following answers: 102871 , 275500 .
And Allah knows best.