Amr bin Shu'ayb narrates from his father, from his grandfather (may Allah be pleased with him), that the Messenger of Allah (peace and blessings be upon him) said: "On Friday, angels sit at the doors of the mosques. They note the times of people's arrival until the imam comes, and when the imam comes, the registers are rolled up and the pens are lifted, and the angels say to one another: 'What has held back so-and-so? What has held back so-and-so?'" The Prophet (peace and blessings be upon him) said: "The angels say: 'O Allah, if he is ill, cure him; if he has gone astray, guide him; and if he is poor, make him free of need.'"
Hadith Referenceالسنن الكبرى للبيهقي / كتاب الجمعة / 5864