What do the scholars of shari’ah say:If the funeral prayer was performed by the Wali of the deceased or by someone who had been granted his permission at the beginning time of Asr Salah, but before the Asr Salah had been performed, will this funeral prayer be valid? If the funeral prayer was valid, but someone repeated it after the Asr Salah thinking that it was invalid to perform it before Asr, will such a person be classed as an innovator?
The funeral prayer is permissible at all times to the extent that it is even permissible to perform it in the three Makruh times, on the condition that the Janaza was brought exactly at that time. The thought that the funeral prayer is impermissible before Asr Salah is absolute ignorance of the Sacred Law, open misguidance and tampering with the Sacred Laws. Yes, if the time for Asr Salah is short, then it is necessary to perform Asr first. But even in this case, if the funeral prayer was performed first then there is no harm. When the Wali or the one who had been given permission from the former had performed the funeral prayer, then no one else can perform the funeral prayer again.
And Allah ﷻ knows best
Imam Ahmad Rida Khan رحمة الله تعالى عليه
Translation by Dr Musharraf Hussain Al-Azhari Translator of Majestic Quran, www.majesticquran.co.uk