We were with the Messenger of Allah ﷺ in a gathering when a man came to him and said, "Messenger of Allah, I have committed an offense that requires a prescribed punishment, so carry out upon me the punishment of Allah's Book."The call to prayer was then made, and the Messenger of Allah ﷺ led us in prayer. When he finished, he left, and the man followed him, and I followed as well.The man said, "Messenger of Allah, I have committed an offense that requires a prescribed punishment, so carry out upon me the punishment of Allah's Book."The Prophet ﷺ said to him, "Did you not leave your home, perform ablution well, and pray with us?"The man replied, "Yes."The Prophet said, "Then Allah has forgiven you your offense," or "your sin."
حدثنا زيد بن الحباب حدثني عكرمة بن عمار اليمامي عن شداد بن عبد الله
كنا مع رسول الله ﷺ في مجلس فجاءه رجل فقال يا رسول الله أصبت حدا فأقم علي كتاب الله قال فأقيمت الصلاة قال فصلى بنا رسول الله ﷺ فلما فرغ خرج رسول الله ﷺ وتبعه الرجل وتبعته فقال يا رسول الله أصبت حدا فأقم علي كتاب الله فقال له النبي ﷺ أليس خرجت من منزلك توضأت فأحسنت الوضوء وصليت معنا قال الرجل بلى قال فإن الله عز وجل قد غفر لك حدك أو ذنبك