What do the expert scholars of shari’ah say: The food is ready and so is the Janaza. Can the food be eaten first or should the deceased be buried prior to it?
If the Janaza is ready, then the funeral prayer should be performed first as there should be no unnecessary delay in such a prayer. However, if there are some necessities such as the food has been brought and he shall be able to participate in the funeral prayer even after consuming the food, or if he was to perform the funeral prayer first then due to hunger his heart will be inclined towards the food, or the food will turn cold and thus taste bad, or his teeth are weak and the chappati shall become cold and hard and he shall not be able to chew, then in such cases he can participate in the burial of the deceased after having eaten the food. He can even suffice on the prayer so as long as there are other people present who shall bury the deceased and his absence shall not cause any harm in the sight of the Sacred Law.
And Allah ﷻ knows best
Imam Ahmad Rida Khan رحمة الله تعالى عليه
Translation by Dr Musharraf Hussain Al-Azhari Translator of Majestic Quran, www.majesticquran.co.uk