I heard the Messenger of Allah ﷺ say, "Hasten with the funeral, for if the deceased was righteous, you are bringing them forward to good, and if they were otherwise, it is an evil that you are setting down from your shoulders."
أخبرنا سويد قال حدثنا عبد الله عن يونس عن الزهري قال حدثني أبو أمامة بن سهل أن
سمعت رسول الله ﷺ يقول أسرعوا بالجنازة فإن كانت صالحة قدمتموها إلى الخير وإن كانت غير ذلك كانت شرا تضعونه عن رقابكم
Muslim narrated it, hadith no. 51/944, from the hadith of Yunus bin Yazid Ayli, in the same manner (see the previous hadith), and it is in Al-Kubra, hadith no. 2038. * Abdullah is Ibn Mubarak.