Abu Waqid reported,

While the Messenger of Allah ﷺ was sitting in the mosque with people gathered around him, three men came along. Two of them approached the Messenger of Allah ﷺ and one walked away.The two stood before the Messenger of Allah ﷺ. One of them noticed a gap in the circle and sat in it. The other sat behind the gathering. The third turned away and left.When the Messenger of Allah ﷺ finished, he said, "Shall I tell you about these three men? As for one of them, he sought refuge with Allah, so Allah gave him refuge. As for the second, he felt shy, so Allah was shy toward him. As for the third, he turned away, so Allah turned away from him."

Muslim 5681

Sahih

حدثنا قتيبة بن سعيد عن مالك بن أنس فيما قرئ عليه عن إسحق بن عبد الله بن أبي طلحة أن أبا مرة مولى عقيل بن أبي طالب أخبره

عن أبي واقد الليثي

أن رسول الله ﷺ بينما هو جالس في المسجد والناس معه إذ أقبل نفر ثلاثة فأقبل اثنان إلى رسول الله ﷺ وذهب واحد قال فوقفا على رسول الله ﷺ فأما أحدهما فرأى فرجة في الحلقة فجلس فيها وأما الآخر فجلس خلفهم وأما الثالث فأدبر ذاهبا فلما فرغ رسول الله ﷺ قال ألا أخبركم عن النفر الثلاثة أما أحدهم فأوى إلى الله فآواه الله وأما الآخر فاستحيا فاستحيا الله منه وأما الآخر فأعرض فأعرض الله عنه

مسلم 5681صحيح
Contents
Reference
Commentary
Ayat
Collection
Sahih Muslim
Book
Peace
Chapter
Whoever comes to a gathering and finds a gap should sit in it, otherwise behind them
Numbering
Darussalam 5681
Muslim 5681