A man came to the Prophet ﷺ and said, "O Prophet of Allah, I took a woman in the garden, and I have done everything with her except that I did not have sexual intercourse with her: I kissed her, fondled her, but did nothing else. So, do with me as you wish." The Messenger of Allah ﷺ did not say anything to him. The man left, and ʿUmar said, "Allah has concealed his fault; if only he had concealed it himself."
The Messenger of Allah ﷺ then followed the man's gaze and said, "Bring him back to me." They brought him back, and the Messenger of Allah ﷺ recited to him, "And establish prayer at the two ends of the day and at the approach of the night. Indeed, good deeds do away with misdeeds. That is a reminder for those who remember. (Hūd 11:114)" Muʿādh b. Jabal asked, "Is this for him alone, O Prophet of Allah, or for all people?" He replied, "No, this is for all people."