[Machine] When the Messenger of Allah ﷺ passed away and condolences were being given, they heard someone saying, "Indeed, in Allah there is consolation from every affliction, a successor from every perishing, and what you have missed out on can still be achieved. So rely on Allah and hope in Him, for the one who is deprived of reward is truly the one who is afflicted." This narration has also been reported from another perspective by Jafar, on the authority of his father, on the authority of Ja'bir, and from another perspective by Anas ibn Malik. However, the chains of narration in these versions are weak and Allah knows best.
لَمَّا تُوُفِّيَ رَسُولُ اللهِ ﷺ وَجَاءَتِ التَّعْزِيَةُ سَمِعُوا قَائِلًا يَقُولُ إِنَّ فِي اللهِ عَزَاءً مِنْ كُلِّ مُصِيبَةٍ وَخَلَفًا مِنْ كُلِّ هَالِكٍ وَدَرَكًا مِنْ كُلِّ مَا فَاتَ فَبِاللهِ فَثِقُوا وَإِيَّاهُ فَارْجُوا فَإِنَّ الْمُصَابَ مَنْ حُرِمَ الثَّوَابَ وَقَدْ رُوِيَ مَعْنَاهُ مِنْ وَجْهٍ آخَرَ عَنْ جَعْفَرٍ عَنْ أَبِيهِ عَنْ جَابِرٍ وَمِنْ وَجْهٍ آخَرَ عَنْ أَنَسِ بْنِ مَالِكٍ وَفِي أَسَانِيدِهِ ضَعْفٌ وَاللهُ أَعْلَمُ