[Machine] I heard the Messenger of Allah ﷺ saying, "When one of you finds defecation, let him start with it before the prayer." This is the narration of Imam Al-Shafi'i and in the narration of Al-Alawi, he said about the Prophet ﷺ , "When the prayer approaches and a man wants to go to the toilet, let him start with relieving himself."
سَمِعْتُ رَسُولَ اللهِ ﷺ يَقُولُ إِذَا وَجَدَ أَحَدُكُمُ الْغَائِطَ فَلْيَبْدَأْ بِهِ قَبْلَ الصَّلَاةِ لَفْظُ حَدِيثِ الشَّافِعِيِّ وَفِي حَدِيثِ الْعَلَوِيِّ قَالَ عَنِ النَّبِيِّ ﷺ إِذَا حَضَرَتِ الصَّلَاةُ وَأَرَادَ الرَّجُلُ الْخَلَاءَ فَلْيَبْدَأْ بِالْخَلَاءِ