By Allah, the Messenger of Allah ﷺ performed the funeral prayer over Suhayl bin Bayda only in the mosque.Ibn Majah said, "The hadith of Ayesha is stronger."
حدثنا أبو بكر بن أبي شيبة حدثنا يونس بن محمد حدثنا فليح بن سليمان عن صالح بن عجلان عن عباد بن عبد الله بن الزبير
والله ما صلى رسول الله ﷺ على سهيل ابن بيضاء إلا في المسجد قال ابن ماجة حديث عائشة أقوى
[Sahih]. Reported by Abu Dawud, in the Book of Funerals, Chapter on Performing the Funeral Prayer in the Masjid, hadith 3189, from the hadith of Fulayh, with this wording.Salih is obscure (mastur), not deemed reliable by anyone except Ibn Hibban, and Bukhari said, "Salih's report from Abbad is mursal." He is corroborated by Muhammad bin Abdullah bin Abbad in Abu Dawud's version, hadith 3189, though he too is unknown (as noted in Taqrib).This hadith has a sahih corroborating witness in Muslim, hadith 973, and elsewhere. There is no real contradiction between the two hadiths, this one indicates the permissibility of performing the funeral prayer in the masjid when there is a valid excuse, while the first hadith is understood to apply to the general, ordinary situation.